A Rollup plugin that automatically resolves named exports from CommonJS modules to avoid the 'is not exported by module' error. Version 1.0.0-beta.3. Base on rollup-plugin-commonjs, it scans modules and generates namedExports configuration automatically. Release cadence: low, beta stage. Key differentiator: eliminates manual namedExports configuration in rollup-plugin-commonjs. Alternative to manual namedExports or @rollup/plugin-commonjs namedExports. Note: tree-shaking may be affected, use with caution for production builds.
npm install rollup-plugin-auto-named-exportsVerified import paths — ran on the pinned version, not inferred.
Basic setup with rollup-plugin-node-resolve, rollup-plugin-commonjs, and auto-named-exports to automatically resolve named exports.
Use manual namedExports if tree-shaking is critical; avoid this plugin in production builds where bundle size matters.
Migrate to @rollup/plugin-commonjs and consider using its namedExports or other solutions.
Use only when necessary; for large projects, specifcy namedExports manually.
Test thoroughly in your environment, consider alternatives for production.
Add rollup-plugin-auto-named-exports to automatically resolve named exports.
Ensure commonjs() plugin is added to plugins array before autoNamedExports() as shown in quickstart.
Use alternative solutions like @rollup/plugin-commonjs with namedExports manually or upgrade the plugin if a newer version exists.