{"_id":"urlencode","_rev":"3018245","name":"urlencode","description":"encodeURIComponent with charset","dist-tags":{"latest":"2.0.0"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"time":{"modified":"2023-11-02T08:18:59.000Z","created":"2012-10-31T15:00:41.684Z","2.0.0":"2023-10-28T13:11:40.371Z","1.1.0":"2015-08-13T17:04:32.435Z","1.0.1":"2015-07-06T07:43:05.547Z","1.0.0":"2015-04-03T16:19:14.836Z","0.2.0":"2014-04-25T13:12:44.480Z","0.1.2":"2014-04-09T13:19:02.259Z","0.1.1":"2014-02-25T02:27:09.831Z","0.1.0":"2014-02-24T06:07:55.971Z","0.0.1":"2012-10-31T15:00:41.684Z"},"users":{"helloncanella":true,"temasm":true,"rbecheras":true,"matteo.collina":true,"jtsky":true,"modao":true,"solee":true,"zuizuihao":true,"hexcola":true,"sn0wdr1am":true,"fanjieqi":true,"fengmk2":true},"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"versions":{"2.0.0":{"name":"urlencode","version":"2.0.0","description":"encodeURIComponent with charset","scripts":{"test":"egg-bin test","ci":"npm run lint && egg-bin cov && npm run prepublishOnly && npm run benchmark","lint":"eslint . --ext ts","benchmark":"node benchmark/urlencode.cjs && node benchmark/urlencode.decode.cjs","prepublishOnly":"tshy && tshy-after"},"dependencies":{"iconv-lite":"~0.6.3"},"devDependencies":{"@eggjs/tsconfig":"^1.3.3","@types/mocha":"^10.0.3","@types/node":"^20.8.7","beautify-benchmark":"^0.2.4","benchmark":"^2.1.4","egg-bin":"^6.5.2","eslint":"^8.51.0","eslint-config-egg":"^13.0.0","git-contributor":"^2.1.5","tshy":"^1.5.0","tshy-after":"^1.0.0","typescript":"^5.2.2"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","tshy":{"exports":{"./package.json":"./package.json",".":"./src/index.ts"}},"exports":{"./package.json":"./package.json",".":{"import":{"types":"./dist/esm/index.d.ts","default":"./dist/esm/index.js"},"require":{"types":"./dist/commonjs/index.d.ts","default":"./dist/commonjs/index.js"}}},"main":"./dist/commonjs/index.js","types":"./dist/commonjs/index.d.ts","type":"module","_id":"urlencode@2.0.0","gitHead":"e7a237f1f34f39ec736771647802e3538e9d8ab4","bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_nodeVersion":"18.18.2","_npmVersion":"9.8.1","dist":{"shasum":"dd0c884d5cfb08adc76607ca3b9431165468695f","size":9258,"noattachment":false,"key":"/urlencode/-/urlencode-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-2.0.0.tgz"},"_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"directories":{},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/urlencode_2.0.0_1698498700207_0.4182012508653834"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-10-28T13:11:40.371Z","publish_time":1698498700371,"_source_registry_name":"default","_cnpm_publish_time":1698498700371},"1.1.0":{"name":"urlencode","version":"1.1.0","description":"encodeURIComponent with charset","main":"lib/urlencode.js","files":["lib"],"scripts":{"test":"mocha -R spec -t 20000 -r should test/*.test.js","test-cov":"istanbul cover node_modules/.bin/_mocha -- -t 20000 -r should test/*.test.js","test-travis":"istanbul cover node_modules/.bin/_mocha --report lcovonly -- -t 20000 -r should test/*.test.js","jshint":"jshint .","autod":"autod -w --prefix '~' -t test -e examples","cnpm":"npm install --registry=https://registry.npm.taobao.org","benchmark":"node benchmark/urlencode.js && node benchmark/urlencode.decode.js"},"dependencies":{"iconv-lite":"~0.4.11"},"devDependencies":{"autod":"*","beautify-benchmark":"*","benchmark":"*","blanket":"*","contributors":"*","istanbul":"~0.3.17","jshint":"*","mocha":"*","should":"7"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"},{"name":"azbykov","email":"azbykov@yamoney.ru","url":"https://github.com/azbykov"},{"name":"alsotang","email":"alsotang@gmail.com","url":"https://github.com/alsotang"},{"name":"twang","email":"twsharp@126.com","url":"https://github.com/twang3"}],"gitHead":"e12310e90dd87e45cdee6360fbd4395d2575d741","bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_id":"urlencode@1.1.0","_shasum":"1f2ba26f013c85f0133f7a3ad6ff2730adf7cbb7","_from":".","_npmVersion":"2.13.3","_nodeVersion":"3.0.0","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"dist":{"shasum":"1f2ba26f013c85f0133f7a3ad6ff2730adf7cbb7","size":3934,"noattachment":false,"key":"/urlencode/-/urlencode-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-1.1.0.tgz"},"directories":{},"publish_time":1439485472435,"_cnpm_publish_time":1439485472435,"_hasShrinkwrap":false},"1.0.1":{"name":"urlencode","version":"1.0.1","description":"encodeURIComponent with charset","main":"lib/urlencode.js","files":["lib/urlencode.js"],"scripts":{"test":"mocha -R spec -t 20000 -r should test/*.test.js","test-cov":"node node_modules/.bin/istanbul cover node_modules/.bin/_mocha -- -t 20000 -r should test/*.test.js","test-travis":"node node_modules/.bin/istanbul cover node_modules/.bin/_mocha --report lcovonly -- -t 20000 -r should test/*.test.js","jshint":"jshint .","autod":"autod -w --prefix '~' -t test -e examples","cnpm":"npm install --registry=https://registry.npm.taobao.org","benchmark":"node benchmark/urlencode.js && node benchmark/urlencode.decode.js"},"dependencies":{"iconv-lite":"~0.4.11","utility":"~1.4.0"},"devDependencies":{"autod":"*","beautify-benchmark":"*","benchmark":"*","blanket":"*","contributors":"*","istanbul":"~0.3.17","jshint":"*","mocha":"*","should":"7"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"},{"name":"azbykov","email":"azbykov@yamoney.ru","url":"https://github.com/azbykov"},{"name":"alsotang","email":"alsotang@gmail.com","url":"https://github.com/alsotang"},{"name":"twang","email":"twsharp@126.com","url":"https://github.com/twang3"}],"gitHead":"cc20923fa08026c37882ce00982909fc4042b68a","bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_id":"urlencode@1.0.1","_shasum":"9de136e68d32407512851e923ec2f275f8e9002a","_from":".","_npmVersion":"2.11.2","_nodeVersion":"0.12.6","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"dist":{"shasum":"9de136e68d32407512851e923ec2f275f8e9002a","size":3897,"noattachment":false,"key":"/urlencode/-/urlencode-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-1.0.1.tgz"},"directories":{},"publish_time":1436168585547,"_cnpm_publish_time":1436168585547,"_hasShrinkwrap":false},"1.0.0":{"name":"urlencode","version":"1.0.0","description":"encodeURIComponent with charset","main":"index.js","scripts":{"test":"make test-all"},"config":{"blanket":{"pattern":"urlencode/lib"},"travis-cov":{"threshold":98}},"dependencies":{"iconv-lite":"~0.4.7","utility":"~1.3.0"},"devDependencies":{"autod":"*","beautify-benchmark":"*","benchmark":"*","blanket":"*","contributors":"*","coveralls":"*","jshint":"*","mocha":"*","mocha-lcov-reporter":"*","should":"~5.2.0","travis-cov":"*"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"},{"name":"azbykov","email":"azbykov@yamoney.ru","url":"https://github.com/azbykov"},{"name":"alsotang","email":"alsotang@gmail.com","url":"https://github.com/alsotang"}],"gitHead":"998856d7e82f526517272f3a1786981bc0f4fdf0","bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_id":"urlencode@1.0.0","_shasum":"e8bb39d897ea727153b26583c0f506be0f848a63","_from":".","_npmVersion":"2.7.4","_nodeVersion":"1.6.3","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"dist":{"shasum":"e8bb39d897ea727153b26583c0f506be0f848a63","size":5700,"noattachment":false,"key":"/urlencode/-/urlencode-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-1.0.0.tgz"},"directories":{},"publish_time":1428077954836,"_cnpm_publish_time":1428077954836,"_hasShrinkwrap":false},"0.2.0":{"name":"urlencode","version":"0.2.0","description":"encodeURIComponent with charset","main":"index.js","scripts":{"test":"make test-all"},"config":{"blanket":{"pattern":"urlencode/lib"},"travis-cov":{"threshold":98}},"dependencies":{"iconv-lite":"0.2.11","utility":"0.1.13"},"devDependencies":{"autod":"*","benchmark":"*","blanket":"*","contributors":"*","coveralls":"*","jshint":"*","mocha":"*","mocha-lcov-reporter":"*","should":"3.3.1","travis-cov":"*"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"},{"name":"azbykov","email":"azbykov@yamoney.ru","url":"https://github.com/azbykov"},{"name":"alsotang","email":"alsotang@gmail.com","url":"https://github.com/alsotang"}],"bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_id":"urlencode@0.2.0","dist":{"shasum":"057c2cd99e5b8aa437f4210e649f4a5e578deafa","size":5091,"noattachment":false,"key":"/urlencode/-/urlencode-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-0.2.0.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"directories":{},"publish_time":1398431564480,"_cnpm_publish_time":1398431564480,"_hasShrinkwrap":false},"0.1.2":{"name":"urlencode","version":"0.1.2","description":"encodeURIComponent with charset","main":"index.js","scripts":{"test":"make test-all"},"config":{"blanket":{"pattern":"urlencode/lib"},"travis-cov":{"threshold":98}},"dependencies":{"iconv-lite":"0.2.11","utility":"0.1.12"},"devDependencies":{"autod":"*","benchmark":"*","blanket":"*","contributors":"*","coveralls":"*","jshint":"*","mocha":"*","mocha-lcov-reporter":"*","should":"3.3.0","travis-cov":"*"},"homepage":"https://github.com/node-modules/urlencode","repository":{"type":"git","url":"git://github.com/node-modules/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"},{"name":"azbykov","email":"azbykov@yamoney.ru","url":"https://github.com/azbykov"}],"bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"_id":"urlencode@0.1.2","dist":{"shasum":"eb353f5ee6b96ca8d8577bd9b95ed22eb75e1f3e","size":4485,"noattachment":false,"key":"/urlencode/-/urlencode-0.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-0.1.2.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"directories":{},"publish_time":1397049542259,"_cnpm_publish_time":1397049542259,"_hasShrinkwrap":false},"0.1.1":{"name":"urlencode","version":"0.1.1","description":"encodeURIComponent with charset","main":"index.js","scripts":{"test":"make test-all"},"config":{"blanket":{"pattern":"urlencode/lib"},"travis-cov":{"threshold":98}},"dependencies":{"iconv-lite":"0.2.11","utility":"0.1.10"},"devDependencies":{"contributors":"*","autod":"*","benchmark":"*","blanket":"*","coveralls":"*","mocha":"*","mocha-lcov-reporter":"*","should":"3.1.2","travis-cov":"*"},"homepage":"https://github.com/fengmk2/urlencode","repository":{"type":"git","url":"git://github.com/fengmk2/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent","querystring","parse"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","contributors":[{"name":"fengmk2","email":"fengmk2@gmail.com","url":"https://github.com/fengmk2"},{"name":"aleafs","email":"zhangxc83@gmail.com","url":"https://github.com/aleafs"}],"bugs":{"url":"https://github.com/fengmk2/urlencode/issues"},"_id":"urlencode@0.1.1","dist":{"shasum":"4be920b55af76ec27b948c3b67dd1ccf97736aef","size":7034,"noattachment":false,"key":"/urlencode/-/urlencode-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-0.1.1.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"directories":{},"publish_time":1393295229831,"_cnpm_publish_time":1393295229831,"_hasShrinkwrap":false},"0.1.0":{"name":"urlencode","version":"0.1.0","description":"encodeURIComponent with charset","main":"index.js","scripts":{"test":"make test-all"},"config":{"blanket":{"pattern":"urlencode/lib"},"travis-cov":{"threshold":98}},"dependencies":{"iconv-lite":"0.2.11","utility":"0.1.10"},"devDependencies":{"autod":"*","benchmark":"*","blanket":"*","coveralls":"*","mocha":"*","mocha-lcov-reporter":"*","should":"3.1.2","travis-cov":"*"},"homepage":"https://github.com/fengmk2/urlencode","repository":{"type":"git","url":"git://github.com/fengmk2/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/fengmk2/urlencode/issues"},"_id":"urlencode@0.1.0","dist":{"shasum":"6f13d84c5438c8cf7f145865ff8e39058281cab9","size":6182,"noattachment":false,"key":"/urlencode/-/urlencode-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-0.1.0.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"directories":{},"publish_time":1393222075971,"_cnpm_publish_time":1393222075971,"_hasShrinkwrap":false},"0.0.1":{"name":"urlencode","version":"0.0.1","description":"encodeURIComponent with charset","main":"index.js","directories":{"test":"test"},"scripts":{"test":"make test && make benchmark"},"dependencies":{"iconv-lite":"0.2.x"},"devDependencies":{"should":"*","benchmark":"*","mocha":"*"},"repository":{"type":"git","url":"git://github.com/fengmk2/urlencode.git"},"keywords":["urlencode","urldecode","encodeURIComponent","decodeURIComponent"],"author":{"name":"fengmk2","email":"fengmk2@gmail.com"},"license":"MIT","readmeFilename":"README.md","_id":"urlencode@0.0.1","dist":{"shasum":"4a279279f02e1748221beae7597272e0162f4ab5","size":2553,"noattachment":false,"key":"/urlencode/-/urlencode-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/urlencode/download/urlencode-0.0.1.tgz"},"_npmVersion":"1.1.65","_npmUser":{"name":"fengmk2","email":"fengmk2@gmail.com"},"maintainers":[{"name":"dead-horse","email":""},{"name":"fengmk2","email":"fengmk2@gmail.com"},{"name":"popomore","email":""}],"publish_time":1351695641684,"_cnpm_publish_time":1351695641684,"_hasShrinkwrap":false}},"readme":"# urlencode\n\n[![NPM version][npm-image]][npm-url]\n[![Node.js CI](https://github.com/node-modules/urlencode/actions/workflows/nodejs.yml/badge.svg)](https://github.com/node-modules/urllib/actions/workflows/nodejs.yml)\n[![Test coverage][codecov-image]][codecov-url]\n[![Known Vulnerabilities][snyk-image]][snyk-url]\n[![npm download][download-image]][download-url]\n\n[npm-image]: https://img.shields.io/npm/v/urlencode.svg?style=flat-square\n[npm-url]: https://npmjs.org/package/urlencode\n[codecov-image]: https://codecov.io/gh/node-modules/urlencode/branch/master/graph/badge.svg\n[codecov-url]: https://codecov.io/gh/node-modules/urlencode\n[snyk-image]: https://snyk.io/test/npm/urlencode/badge.svg?style=flat-square\n[snyk-url]: https://snyk.io/test/npm/urlencode\n[download-image]: https://img.shields.io/npm/dm/urlencode.svg?style=flat-square\n[download-url]: https://npmjs.org/package/urlencode\n\nencodeURIComponent with charset, e.g.: `gbk`\n\n## Install\n\n```bash\nnpm install urlencode\n```\n\n## Usage\n\n```ts\nimport { encode, decode, parse, stringify } from 'urlencode';\n\nconsole.log(encode('苏千')); // default is utf8\nconsole.log(encode('苏千', 'gbk')); // '%CB%D5%C7%A7'\n\n// decode gbk\ndecode('%CB%D5%C7%A7', 'gbk'); // '苏千'\n\n// parse gbk querystring\nparse('nick=%CB%D5%C7%A7', { charset: 'gbk' }); // {nick: '苏千'}\n\n// stringify obj with gbk encoding\nvar str = 'x[y][0][v][w]=' + encode('雾空', 'gbk'); // x[y][0][v][w]=%CE%ED%BF%D5\nvar obj =  {'x' : {'y' : [{'v' : {'w' : '雾空'}}]}};\nassert.equal(urlencode.stringify(obj, { charset: 'gbk' }, str);\n```\n\n## Benchmark\n\n### encode(str, encoding)\n\n```bash\n$ node benchmark/urlencode.cjs\n\nnode version: v21.1.0\n\"苏千测试\\n, 哈哈, haha\"\n\n  urlencode Benchmark\n  node version: v21.1.0, date: Sat Oct 28 2023 21:01:00 GMT+0800 (中国标准时间)\n  Starting...\n  4 tests completed.\n\n  urlencode(str)          x 4,617,242 ops/sec ±2.60% (95 runs sampled)\n  urlencode(str, \"gbk\")   x 1,122,430 ops/sec ±2.20% (95 runs sampled)\n  encodeURIComponent(str) x 4,608,523 ops/sec ±2.94% (93 runs sampled)\n  encodeUTF8(str)         x   833,170 ops/sec ±1.37% (96 runs sampled)\n\nnode version: v20.9.0\n\"苏千测试\\n, 哈哈, haha\"\n\n  urlencode Benchmark\n  node version: v20.9.0, date: Sat Oct 28 2023 21:01:37 GMT+0800 (中国标准时间)\n  Starting...\n  4 tests completed.\n\n  urlencode(str)          x 4,304,468 ops/sec ±2.83% (89 runs sampled)\n  urlencode(str, \"gbk\")   x 1,005,759 ops/sec ±2.10% (90 runs sampled)\n  encodeURIComponent(str) x 4,289,880 ops/sec ±2.99% (92 runs sampled)\n  encodeUTF8(str)         x   827,841 ops/sec ±1.06% (96 runs sampled)\n\nnode version: v18.18.0\n\"苏千测试\\n, 哈哈, haha\"\n\n  urlencode Benchmark\n  node version: v18.18.0, date: Sat Oct 28 2023 19:34:06 GMT+0800 (中国标准时间)\n  Starting...\n  4 tests completed.\n\n  urlencode(str)          x 4,597,865 ops/sec ±0.22% (96 runs sampled)\n  urlencode(str, \"gbk\")   x   633,620 ops/sec ±15.31% (71 runs sampled)\n  encodeURIComponent(str) x 3,902,229 ops/sec ±2.49% (87 runs sampled)\n  encodeUTF8(str)         x   510,456 ops/sec ±26.76% (88 runs sampled)\n\nnode version: v16.20.2\n\"苏千测试\\n, 哈哈, haha\"\n\n  urlencode Benchmark\n  node version: v16.20.2, date: Sat Oct 28 2023 21:02:11 GMT+0800 (中国标准时间)\n  Starting...\n  4 tests completed.\n\n  urlencode(str)          x 4,438,372 ops/sec ±1.80% (93 runs sampled)\n  urlencode(str, \"gbk\")   x 1,175,761 ops/sec ±0.68% (95 runs sampled)\n  encodeURIComponent(str) x 4,374,525 ops/sec ±1.96% (97 runs sampled)\n  encodeUTF8(str)         x   751,616 ops/sec ±2.49% (86 runs sampled)\n\n```\n\n### decode(str, encoding)\n\n```bash\n$ node benchmark/urlencode.decode.cjs\n\nnode version: v21.1.0, date: \"2023-10-28T12:51:20.191Z\"\n\n  urlencode.decode Benchmark\n  node version: v21.1.0, date: Sat Oct 28 2023 20:51:20 GMT+0800 (中国标准时间)\n  Starting...\n  7 tests completed.\n\n  urlencode.decode(str)                        x 515,410 ops/sec ±1.95% (91 runs sampled)\n  urlencode.decode(str, \"gbk\")                 x  54,018 ops/sec ±3.17% (78 runs sampled)\n  decodeURIComponent(str)                      x 313,204 ops/sec ±2.93% (78 runs sampled)\n  urlencode.parse(qs, {charset: \"gbk\"})        x 311,613 ops/sec ±1.26% (95 runs sampled)\n  urlencode.stringify(data, {charset: \"gbk\"})  x 316,558 ops/sec ±1.55% (93 runs sampled)\n  urlencode.parse(qs, {charset: \"utf8\"})       x 490,744 ops/sec ±1.25% (94 runs sampled)\n  urlencode.stringify(data, {charset: \"utf8\"}) x 357,206 ops/sec ±0.46% (97 runs sampled)\n\nnode version: v20.9.0, date: \"2023-10-28T12:49:57.236Z\"\n\n  urlencode.decode Benchmark\n  node version: v20.9.0, date: Sat Oct 28 2023 20:49:57 GMT+0800 (中国标准时间)\n  Starting...\n  7 tests completed.\n\n  urlencode.decode(str)                        x 573,899 ops/sec ±0.62% (95 runs sampled)\n  urlencode.decode(str, \"gbk\")                 x  83,184 ops/sec ±0.13% (100 runs sampled)\n  decodeURIComponent(str)                      x 573,371 ops/sec ±1.67% (93 runs sampled)\n  urlencode.parse(qs, {charset: \"gbk\"})        x 303,202 ops/sec ±0.70% (100 runs sampled)\n  urlencode.stringify(data, {charset: \"gbk\"})  x 319,546 ops/sec ±0.29% (99 runs sampled)\n  urlencode.parse(qs, {charset: \"utf8\"})       x 462,578 ops/sec ±0.25% (98 runs sampled)\n  urlencode.stringify(data, {charset: \"utf8\"}) x 343,487 ops/sec ±0.17% (100 runs sampled)\n\nnode version: v18.18.0, date: \"2023-10-28T12:44:56.355Z\"\n\n  urlencode.decode Benchmark\n  node version: v18.18.0, date: Sat Oct 28 2023 20:44:56 GMT+0800 (中国标准时间)\n  Starting...\n  7 tests completed.\n\n  urlencode.decode(str)                        x 550,451 ops/sec ±1.74% (98 runs sampled)\n  urlencode.decode(str, \"gbk\")                 x  67,311 ops/sec ±1.16% (96 runs sampled)\n  decodeURIComponent(str)                      x 569,461 ops/sec ±0.30% (93 runs sampled)\n  urlencode.parse(qs, {charset: \"gbk\"})        x 293,407 ops/sec ±0.90% (97 runs sampled)\n  urlencode.stringify(data, {charset: \"gbk\"})  x 234,162 ops/sec ±4.55% (75 runs sampled)\n  urlencode.parse(qs, {charset: \"utf8\"})       x 316,697 ops/sec ±4.37% (78 runs sampled)\n  urlencode.stringify(data, {charset: \"utf8\"}) x 192,787 ops/sec ±4.58% (80 runs sampled)\n\nnode version: v16.20.2, date: \"2023-10-28T12:47:38.431Z\"\n\n  urlencode.decode Benchmark\n  node version: v16.20.2, date: Sat Oct 28 2023 20:47:38 GMT+0800 (中国标准时间)\n  Starting...\n  7 tests completed.\n\n  urlencode.decode(str)                        x 537,995 ops/sec ±2.07% (96 runs sampled)\n  urlencode.decode(str, \"gbk\")                 x  78,073 ops/sec ±0.17% (99 runs sampled)\n  decodeURIComponent(str)                      x 558,509 ops/sec ±0.48% (96 runs sampled)\n  urlencode.parse(qs, {charset: \"gbk\"})        x 252,590 ops/sec ±2.87% (90 runs sampled)\n  urlencode.stringify(data, {charset: \"gbk\"})  x 287,978 ops/sec ±2.47% (92 runs sampled)\n  urlencode.parse(qs, {charset: \"utf8\"})       x 416,600 ops/sec ±0.72% (93 runs sampled)\n  urlencode.stringify(data, {charset: \"utf8\"}) x 281,319 ops/sec ±2.43% (85 runs sampled)\n\n```\n\n## License\n\n[MIT](LICENSE.txt)\n","_attachments":{},"homepage":"https://github.com/node-modules/urlencode","bugs":{"url":"https://github.com/node-modules/urlencode/issues"},"license":"MIT"}