ota-meshi / eslint-plugin-regexp

ESLint plugin for finding regex mistakes and style guide violations.

Home Page:https://ota-meshi.github.io/eslint-plugin-regexp/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`regexp/no-super-linear-move`: default for `ignoreSticky` differs from docs

kevinoid opened this issue · comments

Information:

  • ESLint version: 8.50.0
  • eslint-plugin-regexp version: 1.15.0

Description

The documentation for the regexp/no-super-linear-move rule states that the default for the ignoreSticky option is true:

- `ignoreSticky: true` (_default_)

However, the code (and my testing) suggest the default is false:

const ignoreSticky = context.options[0]?.ignoreSticky ?? false

Am I misunderstanding, or should one or the other be changed?

Thanks,
Kevin

Very good find! Thank you for reporting!

The implemented default is indeed incorrect, that should have been ... ?? true.

My pleasure. Thanks for fixing it so quickly!