babel-plugin-rewire-ts
JSON →A Babel plugin that enables mocking of module dependencies for testing, based on the rewire.js concept. The current stable version is 1.4.0, with a release cadence that is maintenance-focused. It is a fork of babel-plugin-rewire with added TypeScript compatibility. Key differentiators: it works with TypeScript, supports ES6 imports, CommonJS require(), and named/top-level function rewiring. It provides a RewireAPI object for convenient mocking in tests. It is specifically designed for unit testing where module dependencies need to be replaced with mocks or stubs.
Traffic · last 30 days stale · no recent hits
total hits 10
actors 4 distinct systems
last hit 20d ago AhrefsBot
top countries 🇺🇸 United States · 🇸🇬 Singapore · 🇨🇦 Canada · 🇩🇪 Germany · 🇬🇧 United Kingdom
Resources
API endpoints
full doc /v1/registry/babel-plugin-rewire-ts
compatibility /v1/registry/babel-plugin-rewire-ts/compatibility