Ctrl + K
DocumentationLog inGet started

tessl/npm-eslint-plugin-regexp

tessl install tessl/npm-eslint-plugin-regexp@2.10.0

ESLint plugin for finding RegExp mistakes and RegExp style guide violations.

Agent Success

Agent success rate when using this tile

82%

Improvement

Agent success rate improvement when using this tile compared to baseline

0.96x

Baseline

Agent success rate without this tile

85%

task.mdevals/scenario-2/

Regex Lint Presets Setup

Configure ESLint to lint regex usage via the regex plugin's built-in presets for both flat and legacy config formats.

Capabilities

Flat configuration

  • npm run lint:flat uses ESLint's flat config format and the plugin's flat preset to lint all JS/TS files in src/; linting src/patterns.js with a duplicate alternative like (foo|foo) exits non-zero and reports the regex issue. @test
  • After replacing the duplicate alternative with a unique pattern, running npm run lint:flat completes with zero errors. @test

Legacy configuration

  • npm run lint:legacy uses a legacy .eslintrc that registers the plugin and extends its legacy preset to lint files in legacy/; linting legacy/replace.js with replaceAll using a non-global regex reports the missing global-flag issue. @test
  • The legacy config ignores legacy/vendor/, so files there are skipped by linting. @test

Implementation

@generates

API

{
  "scripts": {
    "lint:flat": "eslint src",
    "lint:legacy": "eslint --config .eslintrc.cjs legacy"
  }
}

Dependencies { .dependencies }

eslint { .dependency }

JavaScript/TypeScript linting engine.

eslint-plugin-regexp { .dependency }

Provides regex-focused lint rules and presets for flat and legacy config formats.

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
npmpkg:npm/eslint-plugin-regexp@2.10.x
tile.json