* add partial application syntax and some tests * remove unnecessary error message and hasPartial function from parseNewArguments * add types for PartialExpression * Update the tests * rename PartialExpression to Partial * move Partial from expressions to types and rename to ArgumentPlaceholder * add tests for ArgumentPlaceholder in babel-generator * rename Partial to ArgumentPlaceholder * update the tests * remove alias from the type and undo changes in generated folder * adds a nice error message * better definition for the type * auto-generated files * update the conditional for allowPlaceholder message and tests * update CallExpression definition to accept ArgumentPlaceholder * change description * clean up * indent ArgumentPlaceholder entry and revert unwanted changes
14 lines
275 B
JavaScript
14 lines
275 B
JavaScript
import { declare } from "@babel/helper-plugin-utils";
|
|
|
|
export default declare(api => {
|
|
api.assertVersion(7);
|
|
|
|
return {
|
|
name: "syntax-partial-application",
|
|
|
|
manipulateOptions(opts, parserOpts) {
|
|
parserOpts.plugins.push("partialApplication");
|
|
},
|
|
};
|
|
});
|