Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved no-assertion-capturing-group #188

Merged
merged 1 commit into from May 1, 2021

Conversation

RunDevelopment
Copy link
Collaborator

This brings over half of clean-regex/no-constant-capturing-group.

Also, I think we should rename the rule. Even before this update, it also rightfully reported /()a/ even though () obviously doesn't contain assertions. Maybe no-empty-capturing-group (because the captured text is always the empty string)?

@ota-meshi
Copy link
Owner

Even before this update, it also rightfully reported /()a/ even though () obviously doesn't contain assertions.

I didn't intend it in this rule 😅. But I think it's good to rename the rule as you say.

Copy link
Owner

@ota-meshi ota-meshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you!

@ota-meshi ota-meshi merged commit 727bff2 into master May 1, 2021
@ota-meshi ota-meshi deleted the no-assertion-capturing-group-update branch May 1, 2021 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants