An open API service indexing awesome lists of open source software.

https://github.com/kiranps/url-search-params-update

set, get and delete search params from url
https://github.com/kiranps/url-search-params-update

javascript update-url-search-parms url url-parser url-search-parms

Last synced: about 1 month ago
JSON representation

set, get and delete search params from url

Awesome Lists containing this project

README

          

# URL Search Params Update

> set, get and delete search params from url

## Install

```sh
npm install --save url-search-params-update
```

## Usage

```js
import params from 'url-search-params-update'

console.log(location.search)
//=> '?foo=bar&x=y'

const foo = params.get("foo")
//=> 'bar'

params.set("foo", "sindresorhus")
//=> '?foo=sindresorhus&x=y'

params.delete("x")
//=> '?foo=sindresorhus'
```

## License

MIT © [Kiran P S]