babel-plugin-import-redirect

JSON →
library 1.1.1 ·javascript maintenance
verified May 27, 2026

A Babel plugin (v1.1.1) that rewrites import, export from, require() and dynamic import() paths to custom destinations, primarily used for mocking in tests. Last updated in 2017, it supports regex-based redirects, extra function handling, and global replacements. Unlike module aliases or webpack resolve aliases, this operates at the Babel AST level, allowing fine-grained control per file. Requires Node >=4 and babel 6/7.

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

top countries 🇺🇸 United States · 🇩🇪 Germany · 🇸🇬 Singapore · 🇨🇦 Canada · 🇫🇷 France