Skip to content
PluginStats

eslint-plugin-regex weekly downloads statistics

By gmullerb · npm · ESLint plugins

ESLint rules using Regular Expression

View on npm Fresh · Dec 6, 2026

eslint-plugin-regex has 357,985 recorded weekly downloads on npm, an increase of 80.2% over the past 30 days, ranking #442 of 3,247 tracked listings.

Weekly downloads
357,985
Official API · Dec 5, 2026
7-day growth
+60.0%
+134.3K weekly downloads
30-day growth
+80.2%
+159.3K weekly downloads
90-day growth
+148%
+213.7K weekly downloads
Rank
#442
▲ 54 in 7 days

About eslint-plugin-regex

<div align="center"> <img src="./.readme/eslint-plugin-regex.webp" alt=""> <h1>ESLint rules using Regular Expressions</h1> </div>

eslint-plugin-regex eslint-plugin-regex NPM Version License  Github repo Gitlab repo


Quick Start

1 . Add dependencies:

package.json:

  "engines" : {
    "node" : ">=6.0.0"
  },
  "devDependencies": {
    "eslint": ">=4.0.0",
    "eslint-plugin-regex": "1.10.0",

2 . Configure eslint:

Short configuration:

.eslintrc.json:

{
  "plugins": [
    "regex"
  ],
  "rules": {
    "regex/invalid": [
      "error", [
        "invalidRegex1",
        "invalidRegexN"
      ]
    ],
    "regex/required": [
      "error", [
        "requiredRegex1",
        "requiredRegexN"
      ],
      "ignoreFilesRegex"
    ]
  }
}

Files will be checked for the absence of invalidRegex1 and invalidRegexN, and for the presence of requiredRegex1 and requiredRegexN, and files with name matching ignoreFilesRegex will not be checked.

Detailed configuration:

.eslintrc.json:

{
  "plugins": [
    "regex"
  ],
  "rules": {
    "regex/invalid": [
      "error", [{
          "regex": "invalidRegex1",
          "replacement": "newValue"
        }, {
          "id": "regexIdN",
          "message": "errorMessageN",
          "regex": "invalidRegexN",
          "files": {
            "ignore": "ignoreFilesRegexN"
          }
        }
      ]
    ],
    "regex/required": [
      "error", [{
          "id": "regexId1",
          "regex": "requiredRegex1",
          "message": "errorMessage1",
          "files": {
            "inspect": "inspectFilesRegex1"
          }
        }, {
          "regex": "requiredRegexN",
          "files": {
            "ignore": "ignoreFilesRegexA",
            "inspect": "inspectFilesRegexZ"
          }
        }
      ]
    ]
  }
}

Files will be checked for:

  • The absence of invalidRegex1 but if found it will be replaced with newValue.
  • The absence of invalidRegexN only in files with name not matching ignoreFilesRegexN, but if found errorMessageN will be shown.
  • The presence of requiredRegex1 only in files with name matching inspectFilesRegex1, but if not found errorMessage1 will be shown.
  • The presence of requiredRegexN only in files with name matching inspectFilesRegexA and not matching ignoreFilesRegexZ.

Goals

The idea is to allow the creation of different eslint rules based on Regular Expressions in order to have some "freedom" to create quick ESLint custom rules.

Rules

NameFixableDescription
regex/invalidYeschecks that specified patterns are not found
regex/requiredNochecks that specified patterns are found

Each rule defines a set of patterns:

Rules

📏 regex/invalid

This rule checks that specified patterns are not found in files, i.e. Invalid patterns.

✏ Example of incorrect code for this rule:

/* eslint regex/invalid: ['error', ['"']] */

const text = 'Hello "My Friend"'

The error message will reflect the exact location, e.g.:

/path/to/some.js
 34:25  error  Invalid regular expression /"/gm found  regex/invalid

✏ Example of correct code for this rule:

/* eslint regex/invalid: ['error', ['"']] */

const text = 'Hello \'My Friend\''
📏 regex/required

This rule looks for specific patterns that must be present in each file, i.e. Required patterns.

✏ Example of incorrect code for this rule:

/* eslint regex/required: ["error", ["^// Copyright My Friend"]] */

const text = 'Hello "My Friend"'

The error message will point to the beginning of the file, e.g.:

/path/to/some.js
 1:1  error  Required regular expression /^\/\/ Copyright My Friend/gm not found in file  regex/required

✏ Example of correct code for this rule:

/* eslint regex/required: ["error", ["^// Copyright My Friend"]] */

// Copyright My Friend
const text = 'Hello "My Friend"'
Options

Both rule has two options:

  • array of patterns definitions to analyze. [REQUIRED]
    • Each pattern definition can be 'Short' or 'Detailed'.
  • a string representing the regular expression for ignoring files for all patterns. [OPTIONAL]
[
  "error",
  [
    "regex1",
    "regexN"
  ],
  "ignoreFilesRegex"
]
The string representing the regular expression

Remember, Slashes (/) are not required in the string that defines the regex,

e.g. To get the following regex /^(test|spec)$/, define:

  • "^(test|spec)$", when using .eslintrc.js or .eslintrc.json.

e.g. To get the following regex /\bhttp:/, define:

  • "\bhttp:", when using .eslintrc.js, or
  • "\\bhttp:", when using .eslintrc.json. (backslash needs to be double in a json file)

e.g. To get the following regex /.*test\.js/, define:…

Description from the npm listing.

  • eslint-plugin-regex
  • eslint
  • regex-rule
  • regex
  • regexp
  • eslint-regex
  • eslint-rule
  • eslint-regex-rule
  • rule
  • expression
  • regular-expression
  • eslint-regular-expression
  • eslint-regular-expression-rule
  • eslintrule
  • regular-expression-rule
  • eslintplugin
  • eslint-plugin
  • plugin
  • coding style
  • coding standards

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

eslint-plugin-regex weekly downloads on npm, last 90 days: 357,985 weekly downloads as of Dec 5, 2026, +148% over 90 days.eslint-plugin-regexWeekly downloads on npm · Last 90 days357,985downloads / week+148% over 90 days050K100K150K200K250K300K350K400KSep 6Sep 21Oct 6Oct 21Nov 5Nov 20Dec 5downloads / weekobservedarchived (Internet Archive)no observationsSep 7, 2026 – Dec 5, 2026 · 90 observations · Updated Dec …pluginstats.com
eslint-plugin-regex weekly downloads on npm, last 90 days: 357,985 weekly downloads as of Dec 5, 2026, +148% over 90 days.

7/30/90-day growth

eslint-plugin-regex weekly downloads growth on npm: +60.0% over 7 days, +80.2% over 30 days, +148% over 90 days.eslint-plugin-regexWeekly downloads growth on npm357,985downloads / week now7-day growth+134,278 weekly downloads+60.0%30-day growth+159,292 weekly downloads+80.2%90-day growth+213,699 weekly downloads+148%Growth vs. nearest observation to each baseline date · Updated Dec 5, 2026pluginstats.com
eslint-plugin-regex weekly downloads growth on npm: +60.0% over 7 days, +80.2% over 30 days, +148% over 90 days.

Ranking history

eslint-plugin-regex npm ranking history: currently #442 (by weekly downloads).eslint-plugin-regexnpm ranking · by weekly downloads · Last 90 days#442current rank#440#460#480#500#520#540#560Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 18, 2026 – Dec 6, 2026 · 44 observations · Updated Dec 5, 2026pluginstats.com
eslint-plugin-regex npm ranking history: currently #442 (by weekly downloads).

Listing placement

All npm3,247 listings · 163 pages · 1,083 shown · page 23, #2 (overall #442)
All npm: every listing in weekly downloads order

Listing placement

ESLint plugins290 listings · 15 pages · page 5, #18 (overall #98)
ESLint plugins: every listing in weekly downloads order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (170)
Recent weekly downloads observations for eslint-plugin-regex
Date (UTC)Weekly downloadsChange vs. previous
357,985+11.5K
346,482+44.5K
302,018+40.7K
261,316+30.2K
231,153+6.9K
224,231+3.5K
220,777-2.9K
223,707-3.7K
227,385-12.5K
239,878-13.3K
253,214+6K
247,172+25.2K
222,011+21.6K
200,420—

Similar npm ESLint plugins plugins

All 20 eslint-plugin-regex alternatives

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/eslint-plugin-regex. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.