-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Parser error on files in node_modules #634
Comments
Strange. I'm not sure where to go on this, though this file should never have been parsed to begin with, since it has no imports/exports. So this is related to #615 / #649. I'm not sure how/if you can set ESLint settings in XO (@jfmengels?) but the same workaround for those issues should work for this too, until the root issue (overparsing of CJS node modules) is solved. |
The way to set ESLint settings in |
Woo! 👏 |
@BarryThePenguin don't get your hopes up too high 😅 I'm pretty sure this should fix your issue without needing the aforementioned workaround, but not 100% sure. Let me know if it doesn't and I'll reopen. |
I'm sure I'll keep you posted if I run into anymore trouble 😰 |
I'm not sure where this issue belongs, I thought I'd start here as it's related to the rules in this package.
I'm using this plugin as it's included with XO. I'm getting an error as a result of the following rules:
import/no-named-as-default
,import/no-named-as-default-member
,import/default
,import/namespace
andimport/named
This happens when I'm importing
browser-sync
. It looks as though BrowserSync has a#! /usr/bin/env node
at the top of their main file, which I assume is causing the issue.So appears there are a few things going on here:
eslint-plugin-import
is parsing files in mynode_modules
folder. I haven't spent much time understanding how this plugin works, I just consume it through XO.browser-sync
has a#! /usr/bin/env node
line at the top of their main file. I'm only aware of using this in node shell scripts, and I don't think the main BrowserSync file is a script#
as the first character in a javascript module fileThere's a few things here and I'm happy to follow up with any changes to the other projects, I just wanted to check with others that the above is correct. Thanks! 😀
The text was updated successfully, but these errors were encountered: