1.1.0 • Published 7 years ago

export-all-loader v1.1.0

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

export-all-loader npm.io issues stars MIT

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