You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/babel-parser/src/parse-error/pipeline-operator-errors.ts
+23-18Lines changed: 23 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -19,8 +19,9 @@ export default {
19
19
// This error is only used by the smart-mix proposal
20
20
PipeBodyIsTighter:
21
21
"Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.",
22
-
PipeTopicRequiresHackPipes:
23
-
'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.',
Copy file name to clipboardExpand all lines: packages/babel-parser/src/plugin-utils.ts
+5-1Lines changed: 5 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -93,7 +93,11 @@ export function validatePlugins(pluginsMap: Map<string, any>) {
93
93
`Plugin conflict between \`["pipelineOperator", { proposal: "hack", topicToken: "#" }]\` and \`${JSON.stringify(["recordAndTuple",pluginsMap.get("recordAndTuple")])}\`.`,
94
94
);
95
95
}
96
-
}elseif(proposal==="smart"&&tupleSyntaxIsHash){
96
+
}elseif(
97
+
!process.env.BABEL_8_BREAKING&&
98
+
proposal==="smart"&&
99
+
tupleSyntaxIsHash
100
+
){
97
101
thrownewError(
98
102
`Plugin conflict between \`["pipelineOperator", { proposal: "smart" }]\` and \`${JSON.stringify(["recordAndTuple",pluginsMap.get("recordAndTuple")])}\`.`,
"throws": "The pipeline plugin requires a \"proposal\" option. \"proposal\" must be one of: \"minimal\", \"fsharp\", \"hack\", \"smart\". See <https://babeljs.io/docs/en/babel-plugin-proposal-pipeline-operator>."
"throws": "The pipeline plugin requires a \"proposal\" option. \"proposal\" must be one of: \"minimal\", \"fsharp\", \"hack\", \"smart\". See <https://babeljs.io/docs/en/babel-plugin-proposal-pipeline-operator>."
4
+
"throws": "The pipeline plugin requires a \"proposal\" option. \"proposal\" must be one of: \"fsharp\", \"hack\". See <https://babeljs.io/docs/en/babel-plugin-proposal-pipeline-operator>."
0 commit comments