Reports non-constant quantifiers in lookaround assertions that could be simplified.
✅ This rule is included in the ts logical presets.
Reports non-constant quantifiers in lookaround assertions that could be simplified.
Lookahead and lookbehind assertions only check whether a pattern matches, not how much text it consumes.
Non-constant quantifiers at the end of lookaheads or start of lookbehinds can be replaced with their minimum.
If you are intentionally using non-constant quantifiers in lookarounds for documentation purposes or if you are building patterns dynamically, you might want to disable this rule.