Babel preset only for import and export plugins.
npm install --save-dev babel-preset-import-export
yarn add babel-preset-import-export --dev
.babelrc
{
"presets": ["import-export"]
}
babel script.js --presets import-export
"amd" | "umd" | "systemjs" | "commonjs" | false
, defaults to "commonjs"
.
Enable transformation of ES6 module syntax to another module type.
Setting this to false
will not transform modules.