-
-
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
import/no-unresolved when using sass-module-importer #1636
Comments
Indeed, that's a bug in sass-module-importer. It needs to either distribute |
Hi @ljharb, I struggled for a while, where indeed I should report this issue. I ended reporting it here based on Node importing |
It's incorrect data in their package.json; please do report it there. If webpack, for example, silently falls back in this case to the "main", then perhaps we should too, but the real issue is in sass-module-importer, so it seems better to cure the disease instead of the symptoms. |
I created another issue in sass-module-importer. I want also to clarify that we're talking about node resolver here (as I'm import sass-module-importer in my gulpfile). I understand your comment that
but is that the design choice, that resolver used in eslint-plugin-import is more strict when resolving imports then the one used internally by Node and I should workaround it just by:
? |
hmm - It was added in #132, seemingly as a workaround for not being able to validate commonjs exports (@benmosher, confirm?) |
In my project package.json I have:
eslint.json
Importing
works fine, but eslint raises
import/no-unresolved
.As far as I debug it the root cause is that sass-module-importer package.json contains
jsnext:main
, which is preffered by a resolver used here, but at the same time sass-module-importer is not distributed with a file thatjsnext:main
points to.Environment
The text was updated successfully, but these errors were encountered: