CtrlK
CommunityDocumentationLog inGet started
Tessl Logo

tessl/npm-babel-plugin-transform-es2015-sticky-regex

tessl install tessl/npm-babel-plugin-transform-es2015-sticky-regex@6.24.0

Babel plugin that transforms ES2015 sticky regex literals to ES5-compatible RegExp constructor calls

Agent Success

Agent success rate when using this tile

100%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.03x

Baseline

Agent success rate without this tile

97%

rubric.jsonevals/scenario-4/

{
  "context": "Evaluates whether the solution configures Babel to rewrite sticky regex literals using @babel/plugin-transform-sticky-regex with @babel/core, relying on a Babel config plugin entry rather than manual regex handling. Focuses on correct transformation behavior for sticky vs non-sticky regex literals while preserving original flags.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Config entry",
      "description": "Babel configuration (e.g., babel.config.json) includes the @babel/plugin-transform-sticky-regex entry in the plugins list and the code loads/uses that config during compilation.",
      "max_score": 30
    },
    {
      "name": "Babel core usage",
      "description": "Compilation is executed through @babel/core APIs (such as transformSync or similar) rather than hand-written regex rewrites, demonstrating the expected peer dependency usage.",
      "max_score": 25
    },
    {
      "name": "Sticky rewrite",
      "description": "Sticky regex literals (/pattern/y, including combinations like /pattern/gy) are emitted as new RegExp(\"pattern\", \"<flags>\") with an identical pattern string and full flag set after transformation.",
      "max_score": 25
    },
    {
      "name": "Non-sticky untouched",
      "description": "Regex literals without the y flag remain unchanged in the compiled output, aligning with @babel/plugin-transform-sticky-regex behavior that targets only sticky regexes.",
      "max_score": 20
    }
  ]
}

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
npmpkg:npm/babel-plugin-transform-es2015-sticky-regex@6.24.x
tile.json