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
[eslint-config-expo] eslint config for expo projects #27915
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.
There's a lot here. The gist is that the config is designed more to be a validator than a code style linter and for developers to add their own rule configurations.
👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎ This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. Ignoring: Next stepsTake a deeper look at the dependencyTake a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev. Remove the packageIf you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency. Mark a package as acceptable riskTo ignore an alert, reply with a comment starting with |
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.
looks like we've got enough feedback and addressed it! let's ship this so we can test it out and iterate on it
@SocketSecurity ignore npm/fsevents@1.2.13 |
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.
Approving this with a few comments:
- I left some inline comments that should be easy to address.
- Would like to replace
plugin:react/recommended
in a follow-up PR. - Would like to update our docs soon to suggest people use this config instead of
eslint-config-universe
. - Unit tests for the linter configuration in a follow-up PR. This has historically been helpful when updating ESLint.
- If possible, I think it'd be good for
eslint-config-universe
to extend this config so we dogfood it.
@SocketSecurity ignore-all |
Why
We want a generic eslint config that we could recommend for all expo react native projects.
How
This starts by copying the
native
config fromeslint-config-universe
. The difference is that we won't include prettier (the cli will have an option to install it separately), and we do includeeslint-plugin-expo
.TODO
Test Plan
Testing locally by installing it on an existing project with yalc
Checklist
npx expo prebuild
& EAS Build (eg: updated a module plugin).