{"bugs":{"url":"https://github.com/mysticatea/regexpp/issues"},"dist":{"shasum":"14d47dec39c4cd37090a12ac243fc981b73b63df","tarball":"https://registry.npmjs.org/regexpp/-/regexpp-2.0.0-beta.0.tgz","fileCount":8,"integrity":"sha512-jTmmohvR5ADdpDhN6odv4gsDy5wKLNJVMqH5DBlLYSIvcdyELo9atEg6Hyeb4tjARCBFcQvJc7gG1dB3V9JSsg==","signatures":[{"sig":"MEYCIQDJMaZY2k+90w8qCzaF2nw/Zal9Jws16SQGA9BAWk8yKwIhAIWwRR/k/MZQbaXbGKMOdB9A4AhK43Ts5HXKDLfotM3k","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1251124,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbK1ApCRA9TVsSAnZWagAAN4MP/ja5hO6miy1QmasvPRq0\nk8cSH/VPL3s3JDAhVyWeuyyHHDOVazMyuwLIbSUj+6z7h8XAJfabWxVcY/yr\nkGnRy+MtVXjqysBbyDcS9ez1bFaGuQB/3INsn46Q2xaFoPahrDDt/MAxbQsJ\nhKKMTXaCVI73eIuqADHy1KIKbJ9YlXEGupTu3fsnetZ81TYbI5Fg8HK4K6EP\nq4fylk9wu1gt2fOXx05bT4Q/XjxKWw3yzuW5CuLl9rBfWnNCD3XQ1E4IMuTz\n1jJgBVViMDbnmIWeBh1R1SJNM0Sr8rjf3MnTXemDDV4r97p2eUpN0UMfM/MD\nDf/BhNVD8v8M0HnEWefWnnHX5434lIhBBM0iZyRyWoKhP9EHqIHReZwCPkUp\n2ajiwBdT7f860J19IlD9yWk0Now2UtanO1ydksz2JtfSXnQc185xEH7sqkd7\nneQFFjhIatqNUuBT8k37Bsk4GI9396cv7rOI0612wDoCwP/J5/vvb0zqfBAX\nrGkL1ciqCMbOJ99mZqhZO7zt/JxbFfeZX5mq2DnN0Zat0Cwzqf5q8aeVgaAf\nv9XGCHpMCMhR/WVsN1d+PXqittX2hECT4NBgv2h5BA+2k3OAS8gb9IJgOI6m\nFUPCx0hPURv9gd5/VTf18isZrCf7OpXKL2CVo4aMv5n4fzUY/5DGSBAXRCwC\nY0YQ\r\n=Quws\r\n-----END PGP SIGNATURE-----\r\n"},"main":"index","name":"regexpp","files":["index.*"],"author":{"url":"https://github.com/mysticatea","name":"Toru Nagashima"},"readme":"# regexpp\n\n[![npm version](https://img.shields.io/npm/v/regexpp.svg)](https://www.npmjs.com/package/regexpp)\n[![Downloads/month](https://img.shields.io/npm/dm/regexpp.svg)](http://www.npmtrends.com/regexpp)\n[![Build Status](https://travis-ci.org/mysticatea/regexpp.svg?branch=master)](https://travis-ci.org/mysticatea/regexpp)\n[![Coverage Status](https://coveralls.io/repos/github/mysticatea/regexpp/badge.svg)](https://coveralls.io/github/mysticatea/regexpp)\n[![Dependency Status](https://david-dm.org/mysticatea/regexpp.svg)](https://david-dm.org/mysticatea/regexpp)\n\nThe regular expression parser for ECMAScript.\n\n## 💿 Installation\n\n```bash\n$ npm install regexpp\n```\n\n- require Node.js 6.5.0 or newer.\n\n## 📖 Usage\n\n```ts\nimport {\n    AST,\n    RegExpParser,\n    RegExpValidator,\n    RegExpVisitor,\n    parseRegExpLiteral,\n    validateRegExpLiteral,\n    visitRegExpAST\n} from \"regexpp\"\n```\n\n### parseRegExpLiteral(source, options?)\n\nParse a given regular expression literal then make AST object.\n\nThis is equivalent to `new RegExpParser(options).parseLiteral(source)`.\n\n- **Parameters:**\n    - `source` (`string | RegExp`) The source code to parse.\n    - `options?` ([`RegExpParser.Options`]) The options to parse.\n- **Return:**\n    - The AST of the regular expression.\n\n### validateRegExpLiteral(source, options?)\n\nValidate a given regular expression literal.\n\nThis is equivalent to `new RegExpValidator(options).validateLiteral(source)`.\n\n- **Parameters:**\n    - `source` (`string`) The source code to validate.\n    - `options?` ([`RegExpValidator.Options`]) The options to validate.\n\n### visitRegExpAST(ast, handlers)\n\nVisit each node of a given AST.\n\nThis is equivalent to `new RegExpVisitor(handlers).visit(ast)`.\n\n- **Parameters:**\n    - `ast` ([`AST.Node`]) The AST to visit.\n    - `handlers` ([`RegExpVisitor.Handlers`]) The callbacks.\n\n### RegExpParser\n\n#### new RegExpParser(options?)\n\n- **Parameters:**\n    - `options?` ([`RegExpParser.Options`]) The options to parse.\n\n#### parser.parseLiteral(source, start?, end?)\n\nParse a regular expression literal.\n\n- **Parameters:**\n    - `source` (`string`) The source code to parse. E.g. `\"/abc/g\"`.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n- **Return:**\n    - The AST of the regular expression.\n\n#### parser.parsePattern(source, start?, end?, uFlag?)\n\nParse a regular expression pattern.\n\n- **Parameters:**\n    - `source` (`string`) The source code to parse. E.g. `\"abc\"`.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n    - `uFlag?` (`boolean`) The flag to enable Unicode mode.\n- **Return:**\n    - The AST of the regular expression pattern.\n\n#### parser.parseFlags(source, start?, end?)\n\nParse a regular expression flags.\n\n- **Parameters:**\n    - `source` (`string`) The source code to parse. E.g. `\"gim\"`.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n- **Return:**\n    - The AST of the regular expression flags.\n\n### RegExpValidator\n\n#### new RegExpValidator(options)\n\n- **Parameters:**\n    - `options` ([`RegExpValidator.Options`]) The options to validate.\n\n#### validator.validateLiteral(source, start, end)\n\nValidate a regular expression literal.\n\n- **Parameters:**\n    - `source` (`string`) The source code to validate.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n\n#### validator.validatePattern(source, start, end, uFlag)\n\nValidate a regular expression pattern.\n\n- **Parameters:**\n    - `source` (`string`) The source code to validate.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n    - `uFlag?` (`boolean`) The flag to enable Unicode mode.\n\n#### validator.validateFlags(source, start, end)\n\nValidate a regular expression flags.\n\n- **Parameters:**\n    - `source` (`string`) The source code to validate.\n    - `start?` (`number`) The start index in the source code. Default is `0`.\n    - `end?` (`number`) The end index in the source code. Default is `source.length`.\n\n### RegExpVisitor\n\n#### new RegExpVisitor(handlers)\n\n- **Parameters:**\n    - `handlers` ([`RegExpVisitor.Handlers`]) The callbacks.\n\n#### visitor.visit(ast)\n\nValidate a regular expression literal.\n\n- **Parameters:**\n    - `ast` ([`AST.Node`]) The AST to visit.\n\n## 📰 Changelog\n\n- [GitHub Releases](https://github.com/mysticatea/regexpp/releases)\n\n## 🍻 Contributing\n\nWelcome contributing!\n\nPlease use GitHub's Issues/PRs.\n\n### Development Tools\n\n- `npm test` runs tests and measures coverage.\n- `npm run build` compiles TypeScript source code to `index.js`, `index.js.map`, and `index.d.ts`.\n- `npm run clean` removes the temporary files which are created by `npm test` and `npm run build`.\n- `npm run lint` runs ESLint.\n- `npm run update:test` updates test fixtures.\n- `npm run update:ids` updates `src/unicode/ids.ts`.\n- `npm run watch` runs tests with `--watch` option.\n\n[`AST.Node`]: src/ast.ts#L4\n[`RegExpParser.Options`]: src/parser.ts#L539\n[`RegExpValidator.Options`]: src/validator.ts#L127\n[`RegExpVisitor.Handlers`]: src/visitor.ts#L204\n","engines":{"node":">=6.5.0"},"gitHead":"3938ad4f7d7d64618a89fe9476587cd5f4c14af5","license":"MIT","scripts":{"lint":"eslint scripts src test --ext .ts","test":"nyc _mocha \"test/*.ts\" --reporter dot --timeout 10000","build":"run-s build:*","clean":"rimraf .temp index.*","watch":"_mocha \"test/*.ts\" --require ts-node/register --reporter dot --timeout 10000 --watch-extensions .ts --watch --growl","pretest":"run-s build lint","version":"npm run -s build","prebuild":"npm run -s clean","prewatch":"npm run -s clean","build:dts":"dts-bundle --name regexpp --main .temp/index.d.ts --out ../index.d.ts","build:tsc":"tsc --module es2015","coveralls":"nyc report --reporter=text-lcov | coveralls","preversion":"npm test","update:ids":"ts-node scripts/update-unicode-ids.ts","postversion":"git push && git push --tags","update:test":"ts-node scripts/update-fixtures.ts","build:rollup":"rollup -c"},"_npmUser":{"name":"mysticatea","email":"star.ctor@gmail.com"},"homepage":"https://github.com/mysticatea/regexpp#readme","keywords":["regexp","regular","expression","parser","validator","ast","abstract","syntax","tree","ecmascript","es2015","es2016","es2017","es2018","annexB"],"repository":{"url":"git+https://github.com/mysticatea/regexpp.git","type":"git"},"_npmVersion":"6.1.0","description":"Regular expression parser for ECMAScript 2018.","directories":{},"maintainers":[{"name":"mysticatea","email":"star.ctor@gmail.com"}],"_nodeVersion":"10.4.0","dependencies":{},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"nyc":"^12.0.2","mocha":"^5.2.0","eslint":"^4.19.1","rimraf":"^2.6.2","rollup":"^0.60.7","ts-node":"^6.1.1","coveralls":"^3.0.1","dts-bundle":"^0.7.3","typescript":"^2.9.2","@types/node":"^10.3.3","npm-run-all":"^4.1.3","@types/mocha":"^5.2.2","rollup-watch":"^4.3.1","@types/eslint":"^4.16.2","eslint-plugin-mysticatea":"^5.0.0-beta.15","rollup-plugin-sourcemaps":"^0.4.2","typescript-eslint-parser":"^16.0.0","rollup-plugin-node-resolve":"^3.3.0"},"_npmOperationalInternal":{"tmp":"tmp/regexpp_2.0.0-beta.0_1529565224684_0.0593522495032206","host":"s3://npm-registry-packages"},"_id":"regexpp@2.0.0-beta.0","version":"2.0.0-beta.0"}