{"name":"string.prototype.matchall","version":"3.0.1","description":"Spec-compliant polyfill for String.prototype.matchAll ESnext proposal.","main":"index.js","scripts":{"pretest":"npm run lint","test":"es-shim-api --bound && npm run tests-only","posttest":"npm run audit","audit":"npm audit","preaudit":"npm install --package-lock --package-lock-only","postaudit":"rm package-lock.json","tests-only":"npm run test:module && npm run test:shim","test:module":"node test","test:shim":"node test/shimmed","prelint":"evalmd *.md","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/ljharb/String.prototype.matchAll.git"},"keywords":["String.prototype.matchAll","matchAll","match","regex","regexp","regular","expression","matches"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/ljharb/String.prototype.matchAll/issues"},"homepage":"https://github.com/ljharb/String.prototype.matchAll#readme","dependencies":{"define-properties":"^1.1.3","es-abstract":"^1.12.0","function-bind":"^1.1.1","has-symbols":"^1.0.0","regexp.prototype.flags":"^1.2.0"},"devDependencies":{"@es-shims/api":"^2.1.2","@ljharb/eslint-config":"^13.0.0","es5-shim":"^4.5.12","es6-shim":"^0.35.4","eslint":"^5.10.0","evalmd":"^0.0.17","foreach":"^2.0.5","object-inspect":"^1.6.0","object.assign":"^4.1.0","object.entries":"^1.0.4","tape":"^4.9.1"},"gitHead":"e2b43c548a10e97156aec73d0f05c579c25e5491","_id":"string.prototype.matchall@3.0.1","_npmVersion":"6.4.1","_nodeVersion":"11.4.0","_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"dist":{"integrity":"sha512-NSiU0ILQr9PQ1SZmM1X327U5LsM+KfDTassJfqN1al1+0iNpKzmQ4BfXOJwRnTEqv8nKJ67mFpqRoPaGWwvy5A==","shasum":"5a9e0b64bcbeb336aa4814820237c2006985646d","tarball":"http://registry-npm.ywwl.com/string.prototype.matchall/download/string.prototype.matchall-3.0.1.tgz","fileCount":21,"unpackedSize":38213,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcEMAiCRA9TVsSAnZWagAAPLoP/0qtYav0KLmvyXqpElph\ne72I62+aUzO+HfO6vRoCf2U0755qhVKsAWKqT7CPOIxLCwLJ0hj1MVOcS534\n3YifzMa7nZiitk/VdahMO2ywTRjVpSnK9lqpBTUM2mPYQG0HN+/jCIa8KLAt\n4QScoebflpya39pGUNGecrEUbXZheONR7DaXRKvGOe1Ug8EtwHLWHKFfo9Bi\nf1ff5IWbDaspefJXWWOs0u6YammhzRcq607Ox4GbG06nF5YBhXYpka+Y8hs8\nSmK/cZ2lh5nftvBA2zu3onav2mhy/fZgEXzQ3M5anhZP7YgpIdR0tNSts5gX\nfEPuNg4ciRw+5gzYEcKP7ZBzMhMfj3bIUzeP2JSXN2fBxNhQs8nRkq3uQeX5\nvdeZkdYOh2kXrG4zuIpjtBz7qeqeJ//LVN+V3yvjhoHHdcQAZK88bN0mRCiO\nd0J6sImpH+c4V1K2X99BWpNBF2brpIkrf2aXaBNcMiiMZ+LcRwBaJGL0HryX\nehi3CfF96rC4rl82P80UmGr4FjSHpQRMMWByrv63iO6oB8ailbVuTIy9ncC/\ndaVsUYG/OScBW6HQrdhD4frfJd8mbF+hE3bYjlTXW+CO1Lj2dFwcc0pI3V5/\n1I0FtmwfWnnvkJRuQKyP1/+m4p3RUMmLUNPwt2tofr6w+CZ4Xsla+pHKefky\nCQwu\r\n=RfHm\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC9WWlJS0U4QFZm5ZVeW7G8LjreTFKr0uujZFNyAnmdJAIhAMl/Z7TFuw2EgemJxYOEZs+S2FDQxi9pOUaMKsbjdq1c"}],"size":9321,"noattachment":false,"key":"/string.prototype.matchall/-/string.prototype.matchall-3.0.1.tgz"},"maintainers":[{"name":"ljharb","email":"ljharb@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/string.prototype.matchall_3.0.1_1544601633379_0.3619226123516741"},"_hasShrinkwrap":false,"readme":"# string.prototype.matchall <sup>[![Version Badge][npm-version-svg]][package-url]</sup>\n\n[![github actions][actions-image]][actions-url]\n[![coverage][codecov-image]][codecov-url]\n[![dependency status][deps-svg]][deps-url]\n[![dev dependency status][dev-deps-svg]][dev-deps-url]\n[![License][license-image]][license-url]\n[![Downloads][downloads-image]][downloads-url]\n\n[![npm badge][npm-badge-png]][package-url]\n\nES2020 spec-compliant shim for String.prototype.matchAll. Invoke its \"shim\" method to shim `String.prototype.matchAll` if it is unavailable or noncompliant.\n\nThis package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment, and complies with the [spec](https://tc39.es/ecma262/#sec-string.prototype.matchall).\n\nMost common usage:\n```js\nconst assert = require('assert');\nconst matchAll = require('string.prototype.matchall');\n\nconst str = 'aabc';\nconst nonRegexStr = 'ab';\nconst globalRegex = /[ac]/g;\nconst nonGlobalRegex = /[bc]/i;\n\n// non-regex arguments are coerced into a global regex\nassert.deepEqual(\n\t[...matchAll(str, nonRegexStr)],\n\t[...matchAll(str, new RegExp(nonRegexStr, 'g'))]\n);\n\nassert.deepEqual([...matchAll(str, globalRegex)], [\n\tObject.assign(['a'], { index: 0, input: str, groups: undefined }),\n\tObject.assign(['a'], { index: 1, input: str, groups: undefined }),\n\tObject.assign(['c'], { index: 3, input: str, groups: undefined }),\n]);\n\nassert.throws(() => matchAll(str, nonGlobalRegex)); // non-global regexes throw\n\nmatchAll.shim(); // will be a no-op if not needed\n\n// non-regex arguments are coerced into a global regex\nassert.deepEqual(\n\t[...str.matchAll(nonRegexStr)],\n\t[...str.matchAll(new RegExp(nonRegexStr, 'g'))]\n);\n\nassert.deepEqual([...str.matchAll(globalRegex)], [\n\tObject.assign(['a'], { index: 0, input: str, groups: undefined }),\n\tObject.assign(['a'], { index: 1, input: str, groups: undefined }),\n\tObject.assign(['c'], { index: 3, input: str, groups: undefined }),\n]);\n\nassert.throws(() => matchAll(str, nonGlobalRegex)); // non-global regexes throw\n\n```\n\n## Tests\nSimply clone the repo, `npm install`, and run `npm test`\n\n[package-url]: https://npmjs.com/package/string.prototype.matchall\n[npm-version-svg]: https://versionbadg.es/es-shims/String.prototype.matchAll.svg\n[deps-svg]: https://david-dm.org/es-shims/String.prototype.matchAll.svg\n[deps-url]: https://david-dm.org/es-shims/String.prototype.matchAll\n[dev-deps-svg]: https://david-dm.org/es-shims/String.prototype.matchAll/dev-status.svg\n[dev-deps-url]: https://david-dm.org/es-shims/String.prototype.matchAll#info=devDependencies\n[npm-badge-png]: https://nodei.co/npm/string.prototype.matchall.png?downloads=true&stars=true\n[license-image]: https://img.shields.io/npm/l/string.prototype.matchall.svg\n[license-url]: LICENSE\n[downloads-image]: https://img.shields.io/npm/dm/string.prototype.matchall.svg\n[downloads-url]: https://npm-stat.com/charts.html?package=string.prototype.matchall\n[codecov-image]: https://codecov.io/gh/es-shims/String.prototype.matchAll/branch/main/graphs/badge.svg\n[codecov-url]: https://app.codecov.io/gh/es-shims/String.prototype.matchAll/\n[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/es-shims/String.prototype.matchAll\n[actions-url]: https://github.com/es-shims/String.prototype.matchAll/actions\n","publish_time":1544601633546,"_cnpm_publish_time":1544601633546,"dist-tags":{"latest":"4.1.0"}}