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
"Use of future reserved word in strict mode" false positive with eslint-env es6 #2134
Comments
|
Most likely we're not apply |
|
Facing the same issue. It's not optimal to have it in the config file in an ES5 and ES6 mixed environment. |
|
You can toggle it on and off in different config files |
|
If I use 2 different config files, won't I have to duplicate all the configs, and they'll get out of sync? I use the extension |
|
Ok, I started working on this (I think it's actually an easy fix), but run into a bunch of things that I can't test and explain. Here's the code that currently applies inline environments: https://github.com/eslint/eslint/blob/master/lib/eslint.js#L306 |
|
I tested the fix and it seems to be working. Hope to see it in the stable version soon. Thanks a lot \o/ |
|
Closed by mistake. We still have an issue where ecmaFeatures aren't applied because we don't read comments until after parsing has already happened. |
|
I'm not really sure if it's worth keeping this issue open. I don't really see a way to fix this without two-stage parsing. |
|
It's such a basic functionality. It needs fixing. |
|
@ilyavolodin we can't leave this. Either we remove the es6 environment or we figure out a way to make this work. We could, in theory, just search for |
ESLint version:
0.17.1(and 67936e0 gives the same results)foo.js:.eslintrc:{ "ecmaFeatures": { "modules": true } }The false positive:
The text was updated successfully, but these errors were encountered: