eslint-plugin-import icon indicating copy to clipboard operation
eslint-plugin-import copied to clipboard

Valid Webpack Alias Import Syntax

Open Tbhesswebber opened this issue 7 years ago • 1 comments

It seems that eslint-plugin-import is much more discriminate about what characters and what parts of a URI are used in an import statement than Webpack is. Is there a complete list anywhere that I can assemble into a section for the readme? Or a section of the code that might be relevant to discovering why the behavior is what it is that I can then create documentation for?

I have a test repository here that shows some of my confusion in App.jsx. The README may shed some additional light on relevant files.

Tbhesswebber avatar Oct 11 '18 16:10 Tbhesswebber

You can have a look at importType.js for the logic to differentiate import types, e.g. absolute, builtin, external, etc. One thing worth noting is that rules in eslint-plugin-import don't treat aliases starting with @ as internal imports.

Regarding you test project, seems you're missing resolve.extensions in webpack.config.js so it can't resolve .jsx files.

ninjaprox avatar Dec 11 '18 09:12 ninjaprox