import-js/eslint-plugin-import

webpackExports: ["namedExport"] is not supported for dynamic imports

Open

#2306 aperta il 18 nov 2021

Vedi su GitHub
 (1 commento) (0 reazioni) (0 assegnatari)JavaScript (1540 fork)batch import
enhancementhelp wanted

Metriche repository

Star
 (4946 star)
Metriche merge PR
 (Merge medio 138g 22h) (3 PR mergiate in 30 g)

Descrizione

Webpack 5 has some new magic comments allowing better tree-shaking. https://webpack.js.org/api/module-methods/#magic-comments

Currently, if a comment in the form /* webpackExports: ["namedExport"] */ is added to a dynamic import, eslint shows an error when checking with the import/dynamic-import-chunkname rule.

Guida contributor