CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-babel--plugin-transform-parameters

Babel plugin that compiles ES2015 default and rest parameters to ES5-compatible code

91

1.02x
Quality

Pending

Does it follow best practices?

Impact

91%

1.02x

Average score across 10 eval scenarios

SecuritybySnyk

Pending

The risk profile of this skill

Overview
Eval results
Files

criteria.jsonevals/scenario-4/

{
  "context": "This criteria evaluates how well the engineer uses Babel's plugin system to solve the console.log transformation problem. The focus is on proper use of Babel's core transformation API, visitor pattern implementation, and AST manipulation capabilities.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Plugin structure",
      "description": "Uses babel.transform or babel.transformSync with a properly structured plugin object containing a visitor",
      "max_score": 20
    },
    {
      "name": "Visitor pattern",
      "description": "Implements a visitor for CallExpression or MemberExpression nodes to locate console.log calls",
      "max_score": 20
    },
    {
      "name": "Scope traversal",
      "description": "Uses path.scope or path.getFunctionParent() to determine the enclosing function context",
      "max_score": 15
    },
    {
      "name": "Function name retrieval",
      "description": "Correctly retrieves the function name from the parent function node (e.g., FunctionDeclaration.id.name or FunctionExpression with assigned name)",
      "max_score": 15
    },
    {
      "name": "AST node creation",
      "description": "Uses @babel/types builders (e.g., t.stringLiteral, t.arrayExpression) to create new AST nodes for the prepended context",
      "max_score": 15
    },
    {
      "name": "Node modification",
      "description": "Correctly modifies the console.log arguments array using path.node.arguments or similar to prepend the context string",
      "max_score": 10
    },
    {
      "name": "Code generation",
      "description": "Returns the transformed code string using the result from babel.transform (result.code)",
      "max_score": 5
    }
  ]
}

tile.json