Stu
Stu

Reputation: 293

Error while running ESLint: Invalid regular expression flags

Hi have recently started a new react native project, however, when i open up my project on atom, i get the above eslint error on every single js file. I've have opened up my past projects and i dont seem to have that error. I am not aware that anything has changed. Can anybody lend a hand?

I am using node version 10.16.3 if that helps.

enter image description here enter image description here

Upvotes: 2

Views: 1797

Answers (1)

Stu
Stu

Reputation: 293

I went to node_modules/eslint/lib/rules/no-octal-escape.js and replaced the line in the screen shot with:

/^(?:[^\\]|\\.)*?\\([0-3][0-7]{1,2}|[4-7][0-7]|[1-7])/u

Upvotes: 7

Related Questions