Skip to content
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

no-missing-imports does not support "exports" in package.json #255

Open
giltayar opened this issue Feb 10, 2021 · 3 comments
Open

no-missing-imports does not support "exports" in package.json #255

giltayar opened this issue Feb 10, 2021 · 3 comments

Comments

@giltayar
Copy link

giltayar commented Feb 10, 2021

When checking for existence of an import, the new "exports" field is not checked.

Example:

If package foo has this package.json:

{
   "exports": {
      "./bar": "./src/bar.js"
   }
}

Then importing it (or requiring it) via

import "foo/bar"

yields a no-missing-import error, when in fact it works (Node >= 12.x).

@david-bojnansky
Copy link

There can be also imports field in package.json which can be used for mappings.

"imports": {
    "#abc/*": "./abc/out/*"
}
import x from '#abc/file'

@BePo65
Copy link

BePo65 commented Feb 14, 2022

Any progress on this? The missing support of "exports" e.g. creates a false positive when using got for fetching web resources.

@giltayar
Copy link
Author

This is implemented in a fork of this package: eslint-community#4. Mysticatea has not been seen for quite a while (which is OK!) so a few people decided to fork and continue developing in the fork.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants