### parseQuery
-Custom implementation to parse a query. See its counterpart, [stringifyQuery](#stringifyquery).
+Custom implementation to parse a query. Must decode query keys and values. See its counterpart, [stringifyQuery](#stringifyquery).
**Signature:**
```typescript
-parseQuery?: typeof originalParseQuery
+parseQuery?: (searchQuery: string) => Record<string, (string | null)[] | string | null>
```
#### Examples
### stringifyQuery
-Custom implementation to stringify a query object. Should not prepend a leading `?`. [parseQuery](#parsequery) counterpart to handle query parsing.
+Custom implementation to stringify a query object. Should not prepend a leading `?`. Should properly encode query keys and values. [parseQuery](#parsequery) counterpart to handle query parsing.
**Signature:**
```typescript
-stringifyQuery?: typeof originalStringifyQuery
+stringifyQuery?: (
+ query: Record<
+ string | number,
+ string | number | null | undefined | (string | number | null | undefined)[]
+ >
+) => string
```
## RouteRecordRaw
- `hash` is now decoded, that way it can be copied over: `router.push({ hash: $route.hash })` and be used directly in [scrollBehavior](/api/#scrollbehavior)'s `el` option.
- When using `push`, `resolve`, and `replace` and providing a `string` location or a `path` property in an object, **it must be encoded** (like in the previous version). On the other hand, `params`, `query` and `hash` must be provided in its unencoded version.
- The slash character (`/`) is now properly decoded inside `params` while still producing an encoded version on the URL: `%2F`.
+- The `+` character (`%2B` in its encoded form) no longer receives special treatment when found on the query section of the URL. It used to be encoded to deal with [legacy systems using `application/x-www-form-urlencoded`](https://url.spec.whatwg.org/#urlencoded-parsing). This can still be customized when providing custom [parsing and stringifying for `query`](/api/#stringifyquery) because they are responsible of encoding and decoding query params.
**Reason**: This allows to easily copy existing properties of a location when calling `router.push()` and `router.resolve()`, and make the resulting route location consistent across browsers. `router.push()` is now idempotent, meaning that calling `router.push(route.fullPath)`, `router.push({ hash: route.hash })`, `router.push({ query: route.query })`, and `router.push({ params: route.params })` will not create extra encoding.
Both `router.match`, and `router.resolve` have been merged together into `router.resolve` with a slightly different signature. [Refer to the API](/api/#resolve) for more details.
-**Reason**: Uniting multiple methods that were use for the same purpose.
+**Reason**: Uniting multiple methods that were used for the same purpose.
### Removal of `router.getMatchedComponents()`