| Server IP : 10.200.247.200 / Your IP : 216.73.217.19 Web Server : Apache System : Linux synergy-usa-sites 6.8.0-138-generic #138-Ubuntu SMP PREEMPT_DYNAMIC Fri Jul 31 22:41:49 UTC 2026 x86_64 User : jeremy ( 1001) PHP Version : 8.4.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/share/node_modules/@babel/plugin-syntax-pipeline-operator/lib/ |
Upload File : |
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var _helperPluginUtils = require("@babel/helper-plugin-utils");
const PIPELINE_PROPOSALS = ["minimal", "fsharp", "hack", "smart"];
const TOPIC_TOKENS = ["^^", "@@", "^", "%", "#"];
const documentationURL = "https://babeljs.io/docs/en/babel-plugin-proposal-pipeline-operator";
var _default = (0, _helperPluginUtils.declare)((api, {
proposal,
topicToken
}) => {
api.assertVersion(7);
if (typeof proposal !== "string" || !PIPELINE_PROPOSALS.includes(proposal)) {
const proposalList = PIPELINE_PROPOSALS.map(p => `"${p}"`).join(", ");
throw new Error(`The pipeline plugin requires a "proposal" option. "proposal" must be one of: ${proposalList}. See <${documentationURL}>.`);
}
if (proposal === "hack" && !TOPIC_TOKENS.includes(topicToken)) {
const topicTokenList = TOPIC_TOKENS.map(t => `"${t}"`).join(", ");
throw new Error(`The pipeline plugin in "proposal": "hack" mode also requires a "topicToken" option. "topicToken" must be one of: ${topicTokenList}. See <${documentationURL}>.`);
}
return {
name: "syntax-pipeline-operator",
manipulateOptions(opts, parserOpts) {
parserOpts.plugins.push(["pipelineOperator", {
proposal,
topicToken
}]);
opts.generatorOpts.topicToken = topicToken;
}
};
});
exports.default = _default;
//# sourceMappingURL=index.js.map