babel-plugin-dual-import
JSON →Babel plugin that transforms dynamic import() calls to also fetch associated CSS chunks via a separate importCss helper. v1.2.1 (2018) was the last release; the project is in maintenance mode. It converts `import('./Foo.js')` into `Promise.all([import('./Foo'), importCss('Foo')])`, automatically generating webpack chunk names via magic comments. Key differentiator: it eliminates manual webpack chunk naming for code-splitting with CSS, integrating with webpack-flush-chunks and universal rendering. Unlike raw CSS-in-JS solutions, it works with standard CSS files.
Traffic · last 30 days ↓75% vs prev 7d
total hits 21
actors 7 distinct systems
last hit 4d ago human
top countries 🇺🇸 United States · 🇩🇪 Germany · 🇨🇦 Canada · 🇸🇬 Singapore · EC
Resources
API endpoints
compatibility /v1/registry/babel-plugin-dual-import/compatibility