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

Add new rule no-array-prototype-extensions #1461

Merged
merged 6 commits into from Apr 8, 2022

Conversation

smilland
Copy link
Contributor

@smilland smilland commented Apr 5, 2022

Summary

Fixes #1075
Fixes #922

RFC to be added.

Tests

Test Suites: 107 passed, 107 total
Tests: 3042 passed, 3042 total
Snapshots: 1 passed, 1 total
Time: 20.315 s, estimated 29 s
Ran all test suites.
✨ Done in 21.61s.

docs/rules/no-array-prototype-extensions.md Outdated Show resolved Hide resolved
docs/rules/no-array-prototype-extensions.md Show resolved Hide resolved
lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
lib/rules/no-array-prototype-extensions.js Show resolved Hide resolved
lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
tests/lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
tests/lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
@bmish
Copy link
Member

bmish commented Apr 5, 2022

Thanks for starting on this! I've been wanting to see this rule for a long time.

docs/rules/no-array-prototype-extensions.md Show resolved Hide resolved
docs/rules/no-array-prototype-extensions.md Show resolved Hide resolved
lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
docs/rules/no-array-prototype-extensions.md Show resolved Hide resolved
tests/lib/rules/no-array-prototype-extensions.js Outdated Show resolved Hide resolved
@bmish
Copy link
Member

bmish commented Apr 6, 2022

This is looking pretty good. One tip is to try running this on a real codebase to ensure it works properly and doesn't crash.

@bmish bmish mentioned this pull request Apr 6, 2022
@bmish
Copy link
Member

bmish commented Apr 6, 2022

Another note is that this looks like a candidate to be enabled as a recommended rule in the next major release (#1169).

@smilland smilland marked this pull request as ready for review April 8, 2022 02:51
Copy link
Member

@bmish bmish left a comment

Choose a reason for hiding this comment

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

Nice work on this!

@bmish bmish merged commit ed983a2 into ember-cli:master Apr 8, 2022
@bmish bmish changed the title New Rule no-array-prototype-extensions Add new rule no-array-prototype-extensions Apr 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New Rule no-array-prototype-extensions New Rule: Lint against firstObject/lastObject
2 participants