-
-
Notifications
You must be signed in to change notification settings - Fork 41
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
Bug: import type fails with no-missing-import if node fails to resolve the import #286
Comments
🤔 It sounds like this should be listed in the I wonder if there is a better way to route to the |
yeah this does seem like a really tricky one, I think ideally this would be handled by this plugin, even if it's just a warning, but I can live with ignoring the rule or adding it to |
I think we can just ignore these cases (they should have been caught by ts). the rule and considering enabling it by default in the next major version. 🤔 |
Im of two minds about enabling that by default. On one hand I would rather correctly fix resolving the But on the other hand, that is not a "node" problem, and just ignoring type imports seems to make a world of sense, as we can the the typescript linter handle them. I am currently leaning towards adding |
Environment
ESLint version: 8.57.0
eslint-plugin-n version: 17.7.0
What rule do you want to report?
n/no-missing-import
Link to Minimal Reproducible Example
https://eslint-online-playground.netlify.app/#eNp1kk1uwyAQha+C2KSVYpxFV+mmi96gy5BKrhlbTvFAAUepIt+9A/6JkzQbjJmP94YHZ+5dmcOpaK0GETzf8qa1xgUWfi2wD3BHcBq8Z5UzLZPczyuSS5RYGvSGtmpTP13oZ77m4HWDQRBQNbU4LKQPs9rbAOUHUnuVOFmP9VXswZeusSEbwNUFQqNgxIZaZnVXN5hhhCTCKWEKqqLTge0kMjIe2/HCQWnaFlCBWseSEHT6h9VoNhV3kle6CPmCyYYmJd8n+hwHxlxHUWynP8Z+OhPiAgmAc8ZJvqYIlOm+NExbGevTN457OgflaIvyu6iBEjRIGSY5yWM0km9p1hpFRiQ2FBQc38HGtrBsgHKdOyDbFNSwjY4Anuaj7fVd/AvcxPyAWj6QCHy+iI3YLH3Srea33J3Q3eVfcykliT3v/wAjz/CN
What did you expect to happen?
An import that only imports a
type
should be excluded fromn/no-missing-import
. In the example above,serverless@4
stopped providing theirmain
file, and this causes the linting to failParticipation
Additional comments
No response
The text was updated successfully, but these errors were encountered: