{"library":"babel-plugin-require-root-rewrite","type":"library","category":null,"description":"A Babel plugin that transforms module path aliases (e.g., '~/' or '@') into relative paths, allowing developers to require files relative to a configured project root. Version 1.0.2, stable but low activity. It offers a pattern-based replacement with optional basePath and overrides for multi-root projects. Unlike webpack resolve aliases or TypeScript path mapping, this works purely at the Babel transpilation step, making it suitable for Node.js CJS/ESM builds.","language":"javascript","status":"active","version":"1.0.2","tags":["javascript","babel","babel-plugin"],"last_verified":"Wed May 27","install":[{"cmd":"npm install babel-plugin-require-root-rewrite","imports":["// .babelrc\n{\n  \"plugins\": [\"babel-plugin-require-root-rewrite\"]\n}","import plugin from 'babel-plugin-require-root-rewrite'; // if using programmatic API","// In .babelrc with options\n[\"babel-plugin-require-root-rewrite\", { \"pattern\": \"^~/\", \"basePath\": \"src\" }]"]},{"cmd":"yarn add babel-plugin-require-root-rewrite","imports":[]},{"cmd":"pnpm add babel-plugin-require-root-rewrite","imports":[]}],"homepage":null,"github":"https://github.com/louistakepillz/babel-plugin-require-root-rewrite","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/babel-plugin-require-root-rewrite","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/babel-plugin-require-root-rewrite/compatibility"}}