export-all-loader
v1.1.0
Published
transforms export * from 'xxx' to export {}
Downloads
3
Maintainers
Readme
export-all-loader
Babel preloader for Webpack
Transforms your export * from 'xxx'
to export {...}
which can avoid Object.defineProperty
in IE8.
Installation
$ npm install export-all-loader
Quick Start
webpack config:
module.exports = {
module: {
preLoaders: [
{
test: /\.js$/,
loader: 'export-all'
}
]
}
}
Examples
Input:
export * from 'a.js';
export * from 'b.js';
Output:
import {a1, a2} from 'a.js';
import {b1, b2} from 'b.js';
export {a1, a2, b1, b2}
Problems
- Not support
export default
- Cannot use with
babel-plugin-module-resolver