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-5/

Regex Autofix Assistant

A small module that runs regex-focused linting, applies available autofixes from the regex plugin, and reports remaining suggestions.

Capabilities

Apply autofixes from regex rules

  • When given source code that contains a regex pattern with an autofixable issue (for example, a redundant character class wrapping a single token), the returned summary applies the package's autofix so the pattern is rewritten and records the corresponding rule id in appliedFixes. @test

Report remaining suggestions

  • When linting source with regex issues that the package flags without an autofix, the original code is preserved while suggestions collects the rule id, message, and range for each finding; when applySuggestions is enabled, apply the package-provided suggestion fixes before reporting. @test

Toggle between rule presets

  • Linting the same source with the stricter preset yields at least as many findings as the recommended preset, allowing comparison of how many autofixes and suggestions each preset produces. @test

Implementation

@generates

API

export type RuleCoverage = "recommended" | "all";

export interface LintSummary {
  fixedCode: string;
  appliedFixes: Array<{ ruleId: string; message: string }>;
  suggestions: Array<{ ruleId: string; message: string; range: [number, number] }>;
}

export interface LintOptions {
  config?: RuleCoverage;
  applySuggestions?: boolean;
}

export async function lintRegexSource(source: string, options?: LintOptions): Promise<LintSummary>;

export async function lintRegexFile(inputPath: string, outputPath: string, options?: LintOptions): Promise<LintSummary>;

Dependencies { .dependencies }

eslint-plugin-regexp { .dependency }

Provides regex-focused ESLint rules with autofixes and suggestions. @satisfied-by

Version

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