{"_id":"string-replace-all-ponyfill","_rev":"2-86a2ae4f6a95a4848fc0f1156a8f079b","name":"string-replace-all-ponyfill","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"string-replace-all-ponyfill","version":"1.0.0","description":"`String.prototype.replaceAll` ponyfill.","license":"MIT","author":{"name":"Ivan Nikolić","email":"niksy5@gmail.com","url":"http://ivannikolic.com"},"sideEffects":false,"exports":{".":{"import":"./esm/index.js","require":"./cjs/index.js"},"./package.json":"./package.json"},"main":"cjs/index.js","module":"esm/index.js","directories":{"test":"test"},"scripts":{"build":"rollup --config rollup.config.js","lint":"eslint '{index,lib/**/*,test/**/*}.js'","module-check":"node -e 'require(\"string-replace-all-ponyfill\");' && node --input-type=module -e 'import \"string-replace-all-ponyfill\";'","prepublishOnly":"npm run build && npm run module-check","postpublish":"GITHUB_TOKEN=$GITHUB_RELEASE_TOKEN github-release-from-changelog","release":"np --no-release-draft","test":"npm run lint && npm run test:automated","test:automated":"BABEL_ENV=test karma start","test:automated:watch":"npm run test:automated -- --auto-watch --no-single-run","version":"version-changelog CHANGELOG.md && changelog-verify CHANGELOG.md && git add CHANGELOG.md"},"dependencies":{"escape-string-regexp":"^4.0.0"},"devDependencies":{"@babel/cli":"^7.2.3","@babel/core":"^7.2.2","@babel/plugin-transform-member-expression-literals":"^7.12.1","@babel/plugin-transform-object-assign":"^7.2.0","@babel/plugin-transform-property-literals":"^7.12.1","@babel/plugin-transform-runtime":"^7.2.0","@babel/preset-env":"^7.12.1","@babel/runtime":"^7.2.0","@rollup/plugin-babel":"^5.2.1","@rollup/plugin-commonjs":"^15.1.0","@rollup/plugin-node-resolve":"^9.0.0","changelog-verify":"^1.1.2","core-js":"^2.6.5","eslint":"^7.11.0","eslint-config-niksy":"^9.0.0","eslint-config-prettier":"^6.14.0","eslint-plugin-extend":"^0.1.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jsdoc":"^30.7.3","eslint-plugin-mocha":"^8.0.0","eslint-plugin-node":"^11.1.0","eslint-plugin-prettier":"^3.0.1","eslint-plugin-promise":"^4.1.1","eslint-plugin-unicorn":"^23.0.0","esm":"^3.0.51","github-release-from-changelog":"^2.1.1","husky":"^4.3.0","karma":"^5.2.3","karma-browserstack-launcher":"^1.6.0","karma-chrome-launcher":"^3.1.0","karma-coverage-istanbul-reporter":"^3.0.3","karma-fixture":"^0.2.6","karma-html2js-preprocessor":"^1.1.0","karma-mocha":"^2.0.1","karma-mocha-reporter":"^2.2.5","karma-rollup-preprocessor":"^7.0.0","karma-sourcemap-loader":"^0.3.7","lint-staged":"^10.4.2","mocha":"^8.2.0","np":"^6.5.0","prettier":"^2.1.2","rollup":"^2.32.1","rollup-plugin-istanbul":"^2.0.1","rollup-plugin-node-builtins":"^2.1.2","rollup-plugin-node-globals":"^1.4.0","version-changelog":"^3.1.1"},"engines":{"node":">=10"},"keywords":["string","replaceall","prototype","string.prototype.replaceall","ponyfill"],"repository":{"type":"git","url":"git+https://github.com/niksy/string-replace-all-ponyfill.git"},"bugs":{"url":"https://github.com/niksy/string-replace-all-ponyfill/issues"},"homepage":"https://github.com/niksy/string-replace-all-ponyfill#readme","gitHead":"a86a1bb5bb13b4e19a7b38e40b2bcd66ed99d656","_id":"string-replace-all-ponyfill@1.0.0","_nodeVersion":"12.18.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-BCK+nmGh7avZkjLuv4ZFnqBRHACJJimnyEmika8MFRzjOGkUAtIQFcdzJwNgtYULJEwSsQHJoa6OfzMYHNTZQg==","shasum":"e7aed21cd6c8904e5063a36ca2e3ffba248737ec","tarball":"https://registry.npmjs.org/string-replace-all-ponyfill/-/string-replace-all-ponyfill-1.0.0.tgz","fileCount":10,"unpackedSize":18329,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJf2N5nCRA9TVsSAnZWagAAVvIQAKGmhfhmV+jY/uxPz003\n9oWrr7C3MlMryDN7kEW535H5N7PMlJtkW52Q6qVrQyqbbNxiopKDyRiapc73\nq/F5aGtbj2mbi3Q0bgcDaBgJAAwwWK0HzttJyIqqy0+V52pNcQbWxW2MgHDZ\nVAk1/o5VpZyziqzJSvL/xFni5g1uxVwtE+zhVaDJ3F1N4OLSWP2kjaT+EUEu\n8hiZJAXWAtEwJi5IyLVZwnLJmJg+9rW0No894l2c4LuHdX9nDW47L4V9AVOP\nt5t78LozHyiPiFFh/LWtdltLdg3lms9scMY0kiqNGuyFXWCG/Lx4qk5ki42/\nWfNao89vGqp4BpHCNI+65hdyb7+Qbua1WYWozossSV22PAa1o/7BJo6ta6Ad\n0aNStGCwy2hIwfRJjar1w93aqxQO6j2ZxJBiJPQGLKBJtpAuhL/Zml3cAB7C\nptg/ZmP9vnQWs22QOXOBS6Q5SDPVQs7qvcSn1fKNni/i1vuEE27j9ZoTPU4m\nKWnrjoK7tBuJxteOt38MjgFbtG1FRyjOlbHNPSg6sYPGWimWzNOl7MJp8kW1\n+lRTUcmtjflwvUc5AkpruZN4PJFwelG9py7DAHj39DyMI2UHl6PHJrf5XNBF\nVES7B/o79J6VOnM71W5lzkKmnBciMYM1KN4VshTvhECXxJzeE5jrnHOoWr99\nYxIq\r\n=rSXH\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCzKJiXepo5XOaRiuJI5N+1SiV3bcOByhq3lKR0PZVcnAIhAMeBBlmtF+R3KscF1TqaxmNK3O5hFWPz6vevLI5vCPWy"}]},"_npmUser":{"name":"niksy","email":"niksy5@gmail.com"},"maintainers":[{"name":"niksy","email":"niksy5@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/string-replace-all-ponyfill_1.0.0_1608048230924_0.951193291737789"},"_hasShrinkwrap":false},"1.0.1":{"name":"string-replace-all-ponyfill","version":"1.0.1","description":"`String.prototype.replaceAll` ponyfill.","license":"MIT","author":{"name":"Ivan Nikolić","email":"niksy5@gmail.com","url":"http://ivannikolic.com"},"sideEffects":false,"exports":{".":{"import":"./esm/index.js","require":"./cjs/index.js"},"./package.json":"./package.json"},"main":"cjs/index.js","module":"esm/index.js","directories":{"test":"test"},"scripts":{"build":"rollup --config rollup.config.js","lint":"eslint '{index,lib/**/*,test/**/*}.js'","module-check":"node -e 'require(\"string-replace-all-ponyfill\");' && node --input-type=module -e 'import \"string-replace-all-ponyfill\";'","prepublishOnly":"npm run build && npm run module-check","postpublish":"GITHUB_TOKEN=$GITHUB_RELEASE_TOKEN github-release-from-changelog","release":"np --no-release-draft","test":"npm run lint && npm run test:automated","test:automated":"BABEL_ENV=test karma start","test:automated:watch":"npm run test:automated -- --auto-watch --no-single-run","version":"version-changelog CHANGELOG.md && changelog-verify CHANGELOG.md && git add CHANGELOG.md"},"dependencies":{"escape-string-regexp":"^4.0.0"},"devDependencies":{"@babel/cli":"^7.2.3","@babel/core":"^7.2.2","@babel/plugin-transform-member-expression-literals":"^7.12.1","@babel/plugin-transform-object-assign":"^7.2.0","@babel/plugin-transform-property-literals":"^7.12.1","@babel/plugin-transform-runtime":"^7.2.0","@babel/preset-env":"^7.12.1","@babel/runtime":"^7.2.0","@rollup/plugin-babel":"^5.2.1","@rollup/plugin-commonjs":"^15.1.0","@rollup/plugin-node-resolve":"^9.0.0","changelog-verify":"^1.1.2","core-js":"^2.6.5","eslint":"^7.11.0","eslint-config-niksy":"^9.0.0","eslint-config-prettier":"^6.14.0","eslint-plugin-extend":"^0.1.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jsdoc":"^30.7.3","eslint-plugin-mocha":"^8.0.0","eslint-plugin-node":"^11.1.0","eslint-plugin-prettier":"^3.0.1","eslint-plugin-promise":"^4.1.1","eslint-plugin-unicorn":"^23.0.0","esm":"^3.0.51","github-release-from-changelog":"^2.1.1","husky":"^4.3.0","karma":"^5.2.3","karma-browserstack-launcher":"^1.6.0","karma-chrome-launcher":"^3.1.0","karma-coverage-istanbul-reporter":"^3.0.3","karma-fixture":"^0.2.6","karma-html2js-preprocessor":"^1.1.0","karma-mocha":"^2.0.1","karma-mocha-reporter":"^2.2.5","karma-rollup-preprocessor":"^7.0.0","karma-sourcemap-loader":"^0.3.7","lint-staged":"^10.4.2","mocha":"^8.2.0","np":"^6.5.0","prettier":"^2.1.2","rollup":"^2.32.1","rollup-plugin-istanbul":"^2.0.1","rollup-plugin-node-builtins":"^2.1.2","rollup-plugin-node-globals":"^1.4.0","version-changelog":"^3.1.1"},"engines":{"node":">=10"},"keywords":["string","replaceall","prototype","string.prototype.replaceall","ponyfill"],"repository":{"type":"git","url":"git+https://github.com/niksy/string-replace-all-ponyfill.git"},"bugs":{"url":"https://github.com/niksy/string-replace-all-ponyfill/issues"},"homepage":"https://github.com/niksy/string-replace-all-ponyfill#readme","gitHead":"758491ae645faeccbeead9e5306831cb9ec9eb03","_id":"string-replace-all-ponyfill@1.0.1","_nodeVersion":"12.18.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-/1tB2+8ghCUza6mN+PXWTyIchMv7GWEuHYDkfejY3wgaAr5pr7gxXOS/jfseHZ8pYBSPFHVmqmgDLmJtg6zFLw==","shasum":"1dfbed866d2b6f045c6e507b3d7efa7c99f33aac","tarball":"https://registry.npmjs.org/string-replace-all-ponyfill/-/string-replace-all-ponyfill-1.0.1.tgz","fileCount":10,"unpackedSize":19835,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJf2zh1CRA9TVsSAnZWagAALuoQAIRn8WchJngYIHn5wVBk\npAKgX42ZRmyaj2brYaognCs+yWxdOuQjWlUb7EjKQqL6NNe0JzpyAgzruCbu\nkXQx3QOFFbM5hVJbHpUc2APJLbrcitL+zWMjhDWdYQMe4gjbD6n+wq3mP1Ha\n11WvxVfo3mxHWht0gM0ZK570GOfR6+ZThfdXnNtWtFpbUuYPMCQGOilrNVY5\nb1ipFMNXLLtWH8I1jC60QV2yWAbb+4LV5jNa7d13e1bKE7YYgJxXzbT3O3xv\n/zmJY1iC6VyTyJaKrFAQh7sMwYuiW3XULEEINLwfTVv247pLsVA9hCH+sIJj\nmaTT6TxGW/6vH6YwzegTbjN8FzXiCfNEokNDD0KX0NZvgqTeOOWvicYpzD9D\nBAxp3/5UCzcltiJoF3rk+wToOsQHtC5DxCZqcsv44ct2geePJhGhq+tYBZB9\ny0dX7WnkTIeMqo8RMhV1RQb6Osbla+naarTjIAYO+yP/jqQQNMpVwRJrQpQn\nNLelpe/LDKY1tVWiHJ4ZM2jhdn9ugiEjT09FF/RkfTkl8r5TkxYYtzXsdGKy\nTAuhcdGA7sB+gNJsj7FMKS/F/Sxt/s5glA4M9/5YfwZjGGC+s5kM9ghQkISQ\nhNrw4sJ1DEg5lTpDfGp6ohLMvs2uROqYKoYv1/A4iucr6Z8xm5+wwx5P+h3Y\nWeG0\r\n=R3bR\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCeh4PfZJRXyaR4BUcxGzQGoRxjPNXmdFpSGs4TVjUitwIgbfNVRFEyTVhMNQ9/wW6gVhud0ARPAg1luf4fT8JgZDU="}]},"_npmUser":{"name":"niksy","email":"niksy5@gmail.com"},"maintainers":[{"name":"niksy","email":"niksy5@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/string-replace-all-ponyfill_1.0.1_1608202356998_0.2371068635524194"},"_hasShrinkwrap":false}},"time":{"created":"2020-12-15T16:03:50.923Z","1.0.0":"2020-12-15T16:03:51.084Z","modified":"2022-05-18T20:50:48.160Z","1.0.1":"2020-12-17T10:52:37.148Z"},"maintainers":[{"name":"niksy","email":"niksy5@gmail.com"}],"description":"`String.prototype.replaceAll` ponyfill.","homepage":"https://github.com/niksy/string-replace-all-ponyfill#readme","keywords":["string","replaceall","prototype","string.prototype.replaceall","ponyfill"],"repository":{"type":"git","url":"git+https://github.com/niksy/string-replace-all-ponyfill.git"},"author":{"name":"Ivan Nikolić","email":"niksy5@gmail.com","url":"http://ivannikolic.com"},"bugs":{"url":"https://github.com/niksy/string-replace-all-ponyfill/issues"},"license":"MIT","readme":"# string-replace-all-ponyfill\n\n[![Build Status][ci-img]][ci]\n[![BrowserStack Status][browserstack-img]][browserstack]\n\n[`String.prototype.replaceAll`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll)\n[ponyfill](https://ponyfill.com).\n\n> The `replaceAll()` method returns a new string with all matches of a pattern\n> replaced by a replacement. The pattern can be a string or a `RegExp`, and the\n> replacement can be a string or a function to be called for each match.\n\n## Install\n\n```sh\nnpm install string-replace-all-ponyfill --save\n```\n\n## Usage\n\n```js\nimport replaceAll from 'string-replace-all-ponyfill';\n\nreplaceAll('abba', 'b', 'c'); // acca\n```\n\nYou can **use named export `preferNative` if you wish to use native\nimplementation if it’s available**. In all other cases, ponyfill will be used.\nBeware of\n[caveats](https://github.com/sindresorhus/ponyfill#user-content-ponyfill:~:text=Ponyfills%20should%20never%20use%20the%20native,between%20environments%2C%20which%20can%20cause%20bugs.)!\n\n## API\n\n### replaceAll(stringToReplace, searchValue, replaceValue)\n\nReturns: `string`\n\n#### stringToReplace\n\nType: `string`\n\nString to replace.\n\n#### searchValue\n\nType: `string|RegExp`\n\nIf `string`, `stringToReplace` will be searched for this value.\n\nIf `RegExp`, the matches are replaced with `replaceValue` or the value returned\nby the specified function. A `RegExp` without the global flag will throw a\n`TypeError`.\n\n##### replaceValue\n\nType: `string|Function`\n\nIf `string`, `searchValue` will be replaced with this value. A number of\n[special replacement patterns](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll#Specifying_a_string_as_a_parameter)\nare supported.\n\nIf `Function`, it’s invoked to create the new substring which is used to replace\nthe matches of `searchValue` parameter. See\n[arguments for the function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll#Specifying_a_function_as_a_parameter)).\n\n## Browser support\n\nTested in IE11+ and all modern browsers.\n\n## Acknowledgments\n\n-   [StackOverflow discussion for legacy browser support](https://stackoverflow.com/a/1144788/178058)\n\n## Test\n\nTest suite is taken and modified from following packages:\n\n-   [polyfill-library](https://github.com/Financial-Times/polyfill-library/blob/master/polyfills/String/prototype/replaceAll/tests.js)\n-   [es-shims](https://github.com/es-shims/String.prototype.replaceAll/blob/main/test/tests.js)\n-   [core-js](https://github.com/zloirock/core-js/blob/master/tests/pure/es.string.replace-all.js)\n\nFor automated tests, run `npm run test:automated` (append `:watch` for watcher\nsupport).\n\n## License\n\nMIT © [Ivan Nikolić](http://ivannikolic.com)\n\n<!-- prettier-ignore-start -->\n\n[ci]: https://travis-ci.com/niksy/string-replace-all-ponyfill\n[ci-img]: https://travis-ci.com/niksy/string-replace-all-ponyfill.svg?branch=master\n[browserstack]: https://www.browserstack.com/\n[browserstack-img]: https://www.browserstack.com/automate/badge.svg?badge_key=YWxRMDN6MGFhYWdJMzlRSTBOVXMxSFllQytwWGcyb3ROM3YrSFh2cUNpOD0tLTM0c2RvVEZvSjJ0THhTcjRYSFBqZ1E9PQ==--90d6150a6b3215895fe99e8441c93a87da12a8b5\n\n<!-- prettier-ignore-end -->\n","readmeFilename":"README.md"}