Skip to main content

@babel/plugin-proposal-export-default-from

示例

¥Example

JavaScript
export v from "mod";

安装

¥Installation

npm install --save-dev @babel/plugin-proposal-export-default-from

用法

¥Usage

¥With a configuration file (Recommended)

babel.config.json
{
"plugins": ["@babel/plugin-proposal-export-default-from"]
}

通过 CLI

¥Via CLI

Shell
babel --plugins @babel/plugin-proposal-export-default-from script.js

通过 Node API

¥Via Node API

JavaScript
require("@babel/core").transformSync("code", {
plugins: ["@babel/plugin-proposal-export-default-from"],
});

参考

¥References