{"name":"issue-regex","version":"4.2.0","description":"Regular expression for matching issue references","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/issue-regex.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":"./index.js","types":"./index.d.ts","sideEffects":false,"engines":{"node":"^12.20.0 || ^14.13.1 || >=16.0.0"},"scripts":{"test":"xo && ava && tsd"},"keywords":["issue","issues","pr","pull","request","reference","references","regex","regexp","regular","expression","github","gh","link"],"devDependencies":{"ava":"^6.1.3","tsd":"^0.31.2","xo":"^0.56.0"},"xo":{"rules":{"// Due to https://github.com/avajs/eslint-plugin-ava/issues/344":"off","ava/assertion-arguments":"off"}},"_id":"issue-regex@4.2.0","gitHead":"205ab7128604727af8ee898d42402ef3653782b3","bugs":{"url":"https://github.com/sindresorhus/issue-regex/issues"},"homepage":"https://github.com/sindresorhus/issue-regex#readme","_nodeVersion":"18.20.2","_npmVersion":"10.6.0","dist":{"integrity":"sha512-uXRJWQzWjBWzbgE2VWTA/iT4VXhcH0a7BruAUch0tv4h3tf/Jsw+pXxptmErg4Rb3RwCXUbH9NUd83afNoj/WQ==","shasum":"dd4ccd5bb9628c64769a0a2ac11c0b01407397a2","tarball":"http://registry-npm.ywwl.com/issue-regex/download/issue-regex-4.2.0.tgz","fileCount":5,"unpackedSize":4011,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDh+EuX5KctRPLwhbyy72acZFwwf5sqycsasaQOtgwL2QIgOClrHedh9tZDUgATLQJctizyxuNCHczevEH1xlPGEwc="}],"size":2095,"noattachment":false,"key":"/issue-regex/-/issue-regex-4.2.0.tgz"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/issue-regex_4.2.0_1725713464807_0.5783628897871742"},"_hasShrinkwrap":false,"readme":"# issue-regex\n\n> Regular expression for matching issue references\n\n## Install\n\n```sh\nnpm install issue-regex\n```\n\n## Usage\n\n```js\nimport issueRegex from 'issue-regex';\n\n'Fixes #143 and avajs/ava#1023'.match(issueRegex());\n//=> ['#143', 'avajs/ava#1023']\n```\n\nOrganization name, repository name, and issue number are also available individually in capturing groups 1-3, or named groups `organization`, `repository`, and `issueNumber`:\n\n```js\nissueRegex().exec('Fixes avajs/ava#1023');\n/*\n[\n\t'avajs/ava#1023',\n\t'avajs',\n\t'ava',\n\t'1023',\n\tindex: 6,\n\tinput: 'Fixes avajs/ava#1023',\n\tgroups: {\n\t\torganization: 'avajs',\n\t\trepository: 'ava',\n\t\tissueNumber: '1023'\n\t}\n]\n*/\n```\n\n## API\n\n### issueRegex()\n\nReturns a `RegExp` for matching issue references.\n\n## Important\n\nIf you run the regex against untrusted user input in a server context, you should [give it a timeout](https://github.com/sindresorhus/super-regex).\n\n**I do not consider ReDoS a valid vulnerability for this package.**\n\n## Related\n\n- [linkify-issues](https://github.com/sindresorhus/linkify-issues) - Linkify GitHub issue references\n","publish_time":1725713464981,"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_cnpm_publish_time":1725713464981,"dist-tags":{"latest":"4.3.0"}}