@babel/plugin-proposal-pipeline-operator
Installation
$ npm install --save-dev @babel/plugin-proposal-pipeline-operator
Usage
With a configuration file (Recommended)
{
"plugins": [["@babel/plugin-proposal-pipeline-operator", { "proposal": "minimal" }]]
}
The Pipeline Proposal is one of three competing implementations. Which implementation the plugin should use is configured with the "proposal"
option. This option is required and should be one of:
"minimal"
– Minimal Pipeline"fsharp"
- F#-Style Pipeline (Coming Soon!)"smart"
- Smart Pipeline (Coming Soon!)
Only "minimal" is currently supported. The other two flags are in progress.
When one of the implementations is accepted, it will become the default and the "proposal"
option will no longer be required.
Via CLI
$ babel --plugins @babel/plugin-proposal-pipeline-operator script.js
Via Node API
require("@babel/core").transform("code", {
plugins: ["@babel/plugin-proposal-pipeline-operator"]
});