Update URL-parameters.md
Updated a file that was changed in the meantime
This commit is contained in:
@ -1,7 +1,6 @@
|
||||
### URL parameters
|
||||
|
||||
Use `match()` with an appropriate regular expression to get all key-value pairs, `Array.map()` them appropriately.
|
||||
Combine all key-value pairs into a single object using `Object.assign()` and the spread operator (`...`).
|
||||
Use `match()` with an appropriate regular expression to get all key-value pairs, `Array.reduce()` to map and combine them into a single object.
|
||||
Pass `location.search` as the argument to apply to the current `url`.
|
||||
|
||||
```js
|
||||
|
||||
Reference in New Issue
Block a user