-
Notifications
You must be signed in to change notification settings - Fork 14
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
2731: Add linting rule for arrays #2970
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Congrats to your first PR, nicely done 🚀 Just one small comment regarding the yarn.lock
, I think this is otherwise good to go!
…731-linting-rule-arrays # Conflicts: # tools/yarn.lock
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you 👍
Code Climate has analyzed commit cf8c5ad and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 94.7% (50% is the threshold). This pull request will bring the total coverage in the repository to 74.2%. View more on Code Climate. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very cool, thank you very much for cleaning up 🧽
I have found two more places where we still use the Array
type, one is Selector.ts
in the e2e-tests, the other one in helpers.spec.ts
in native, might be worth a check why the linter doesn't find that. But then again, maybe not 😂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll approve it already since I'll be on vacation for a bit and don't want to block anything :)
Actually I am quite sure that this is something different. The two occurrences mentioned by you are both referring to const keys = new Array<string>() These are initialization of a new array instance (of type string), opposed to something like the following which actually throws an error in both cases: const keys: Array<string> = new Array<string>() I therefore think we are actually good to go here :) |
Woooops, you're right, sorry! |
Short description
Add a linting style for arrays
Proposed changes
Side effects
Testing
Check that all settings still work.
Resolved issues
Fixes: #2731