jviereck / regjsparser

Parsing the JavaScript's RegExp in JavaScript.
http://www.julianviereck.de/regjsparser/
BSD 2-Clause "Simplified" License
77 stars 20 forks source link

Use eslint-plugin-regexp #144

Open JLHwung opened 2 days ago

JLHwung commented 2 days ago

In this PR we introduce an ESLint plugin eslint-plugin-regexp and enable most of its recommended rules. Then we fixed all lint errors for each different rules.

This PR is based on #143 so that that PR is also linted against the new ESLint plugin. I will rebase once that PR gets merged.

jviereck commented 2 days ago

Great! Does npm test run the linter automatically? If not, is there a way to trigger it from npm test and make the test fail if there is a lint error?

JLHwung commented 2 days ago

Does npm test run the linter automatically?

Yes https://github.com/jviereck/regjsparser/blob/47eaf14ab217dec60dd148fbd9b2b221e6c70e79/package.json#L16