Babel plugin that compiles ES2015 default and rest parameters to ES5-compatible code
91
{
"context": "This criteria evaluates how well the engineer configures and uses Babel's runtime helper management system to transform async/await and class features while externalizing helper functions to avoid code duplication. The focus is on proper setup of @babel/plugin-transform-runtime and understanding of how Babel handles runtime helpers.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Babel configuration exists",
"description": "A Babel configuration file (.babelrc, .babelrc.js, .babelrc.json, babel.config.js, or babel.config.json) is present in the project",
"max_score": 10
},
{
"name": "Runtime plugin configured",
"description": "The @babel/plugin-transform-runtime plugin is included in the Babel configuration plugins array",
"max_score": 25
},
{
"name": "Runtime dependency installed",
"description": "The @babel/runtime package is listed as a dependency (not devDependency) in package.json",
"max_score": 15
},
{
"name": "Helper externalization",
"description": "The compiled output uses imported helpers from @babel/runtime/helpers/ instead of inlined helper functions, demonstrating proper externalization of Babel helpers",
"max_score": 20
},
{
"name": "Regenerator handling",
"description": "Async/await and generator code is transformed to use @babel/runtime/regenerator instead of inlining the regenerator runtime",
"max_score": 15
},
{
"name": "Appropriate plugin options",
"description": "The @babel/plugin-transform-runtime plugin is configured with appropriate options (e.g., corejs: false for helper-only mode, or version specification if using corejs)",
"max_score": 10
},
{
"name": "Correct implementation",
"description": "The async utilities (asyncMap, collectAsync, AsyncQueue) are correctly implemented and all test cases pass",
"max_score": 5
}
]
}Install with Tessl CLI
npx tessl i tessl/npm-babel--plugin-transform-parametersdocs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10