Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BREAKING: Handle ES2018 capture names #247

Merged
merged 14 commits into from Jan 9, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions .babelrc
@@ -1,5 +1,6 @@
{
"plugins": [
["@babel/plugin-proposal-unicode-property-regex", { "useUnicodeFlag": false }],
[
"@babel/plugin-transform-runtime",
{
Expand Down
1 change: 1 addition & 0 deletions .eslintrc.js
Expand Up @@ -7,6 +7,7 @@ module.exports = {
},
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": 9,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does this do?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It allows the eslint parser to support the new syntax in src/xregexp.js, rather than showing an error like this:

/Users/josephfrazier/workspace/xregexp/src/xregexp.js
  1847:6  error  Parsing error: Invalid regular expression: /\(\?P?<([\p{ID_Start}$_][\p{ID_Continue}$_\u200C\u200D]*)>/: Invalid escape

"sourceType": "module"
},
"rules": {
Expand Down