babel-plugin-transform-barrels

JSON →
library 1.0.23 ·javascript
verified May 27, 2026

A Babel plugin that transforms indirect imports through barrel files (index.js) into direct imports. Current stable version is 1.0.23. The plugin supports Webpack, Vite, and Jest, resolving imports to improve bundling performance and avoid circular dependencies. Key differentiators include support for package.json exports field, jest.mock/requireActual, Webpack aliases, and caching. It is designed to be used as a Babel plugin with minimal configuration, offering options like alias, extensions, modulesDirs, and moduleIgnorePatterns. Version 1.0.23 adds moduleIgnorePatterns and fixes jest.mock bugs.

total hits 21
actors 7 distinct systems
last hit 2d ago AhrefsBot
MetaBot
4
ByteDance
3
GPTBot
2
Script
1
Search engines
1
Humans
2

top countries 🇺🇸 United States · 🇩🇪 Germany · 🇸🇬 Singapore · 🇨🇦 Canada · 🇬🇧 United Kingdom