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

explicit-length-check: Make rule work in many more cases #943

Merged
merged 14 commits into from
Dec 21, 2020

Conversation

fisker
Copy link
Collaborator

@fisker fisker commented Dec 21, 2020

All these expressions compare to a number they return a boolean, it don't has to be in if, now all fixed.

The only thing we are not sure is foo.length (!foo.length is sure, handled in 'UnaryExpression' selector), to make sure it's a boolean, we checked it in if/while etc.

@fisker fisker marked this pull request as ready for review December 21, 2020 03:21
@sindresorhus sindresorhus merged commit f3bc798 into sindresorhus:master Dec 21, 2020
@fisker fisker deleted the explicit-length-check-2 branch December 22, 2020 07:35
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.

2 participants