babel-plugin-replace-import-src-to-where
v1.2.1
Published
fix import or require path from src to somewhere when compiler
Downloads
21
Maintainers
Readme
babel-plugin-replace-import-src-to-where
make your import or require path from this
import aaa from "src/file/aaa/path";
var bbb = require("src/file/bbb/path");
var config = {
ccc: "src/file/ccc/path"
}
to this
import aaa from "lib/file/aaa/path";
var bbb = require("lib/file/bbb/path");
var config = {
ccc: "lib/file/ccc/path"
}
Install
$ npm install babel-plugin-replace-import-src-to-where
Usage for your .babelrc
{
"env": {
"dev": {
"plugins": [
"replace-import-src-to-where"
]
}
}
}