{"id":18905063,"url":"https://github.com/kenberkeley/update-query","last_synced_at":"2026-03-04T18:30:19.792Z","repository":{"id":143891836,"uuid":"77451772","full_name":"kenberkeley/update-query","owner":"kenberkeley","description":"Update the query string of a url with the given object","archived":false,"fork":false,"pushed_at":"2017-03-21T06:29:12.000Z","size":7,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-15T03:12:23.471Z","etag":null,"topics":["qs","querystring"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kenberkeley.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-12-27T11:50:56.000Z","updated_at":"2019-01-20T12:42:04.000Z","dependencies_parsed_at":null,"dependency_job_id":"e2153bcd-0137-4d0a-8744-24a314bb86b3","html_url":"https://github.com/kenberkeley/update-query","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenberkeley%2Fupdate-query","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenberkeley%2Fupdate-query/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenberkeley%2Fupdate-query/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenberkeley%2Fupdate-query/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kenberkeley","download_url":"https://codeload.github.com/kenberkeley/update-query/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239889026,"owners_count":19713702,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["qs","querystring"],"created_at":"2024-11-08T09:10:30.645Z","updated_at":"2026-03-04T18:30:19.728Z","avatar_url":"https://github.com/kenberkeley.png","language":"JavaScript","readme":"# updateQuery(url, Object)\r\n\r\n[![npm version][npm-v-img]][npm-url]\r\n[![npm download][npm-dl-img]][npm-url]\r\n[![build][build-img]][build-url]\r\n\r\n\u003e Update the query string of a url with the given object\r\n\r\n### Installation\r\n\r\n`npm i update-query -S`  \r\n\u003e alternatively：`\u003cscript src=\"dist/update-query.min.js\"\u003e\u003c/script\u003e`\r\n\r\n### Usage\r\n\u003e Any falsey value is omitted except `0`\r\n\r\n```\r\n\u003e updateQuery('test.com?a=1', { b: 2 })\r\n'test.com?a=1\u0026b=2'\r\n\r\n\u003e updateQuery('test.com?a=1\u0026b=2', { a: 0, b: 3 })\r\n'test.com?a=0\u0026b=3'\r\n\r\n\u003e updateQuery('test.com?a=1\u0026b=2', { a: '', b: null })\r\n'test.com'\r\n```\r\n\r\n### Build\r\n\r\n`npm run build`, output will be piped into `dist/`\r\n\r\n\r\n### Test \u0026 Coverage\r\n\r\n`npm test` \u0026 `npm run cov`\r\n\r\n[npm-url]: https://www.npmjs.com/package/update-query\r\n[npm-v-img]: http://img.shields.io/npm/v/update-query.svg\r\n[npm-dl-img]: http://img.shields.io/npm/dm/update-query.svg\r\n[build-img]: https://travis-ci.org/kenberkeley/update-query.svg?branch=master\r\n[build-url]: https://travis-ci.org/kenberkeley/update-query\r\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkenberkeley%2Fupdate-query","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkenberkeley%2Fupdate-query","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkenberkeley%2Fupdate-query/lists"}