javascript-invat-eu-inveti-si-tu
eslint-plugin-react
javascript-invat-eu-inveti-si-tu | eslint-plugin-react | |
---|---|---|
1 | 73 | |
62 | 9,007 | |
- | 0.1% | |
3.9 | 9.1 | |
11 months ago | 5 days ago | |
JavaScript | JavaScript | |
- | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
javascript-invat-eu-inveti-si-tu
eslint-plugin-react
-
Setup ESLint, Prettier, Husky with Vite
Install eslint-plugin-react and update the config:
-
HTML Form Validation is heavily underused
One of my favorite eslint rules to enable: https://github.com/jsx-eslint/eslint-plugin-react/blob/maste...
-
What's Coming Next for ESLint
> It is also possible to install ESLint globally, rather than locally, using npm install eslint --global. However, this is not recommended, and any plugins or shareable configs that you use must still be installed locally if you install ESLint globally.
Which means that simple stuff like just adding the airbnb or eslint recommended settings can now only be done locally.
More discussion here: https://github.com/jsx-eslint/eslint-plugin-react/issues/233...
- Setup Eslint + Prettier para padronização de código em React
-
Setup Eslint + Prettier for code standardization in React
[email protected]: it will add version 8.57.0 (the latest version below 9) due to some issues related to the React plugin from version 9 onwards, which are currently being analyzed
-
Mastering Code Quality: Setting Up ESLint with Standard JS in TypeScript Projects
JavaScript Standard Style is less opinionated about JSX formatting and largely leaves JSX as-is. In a React project, you should integrate with React-specific linting rules for ESLint. The generally accepted configurations are eslint-plugin-react and eslint-plugin-react-hooks, enforcing some best practices of writing React code.
-
Interesting Bugs Caught by ESLint's no-constant-binary-expression
> [1] https://github.com/jsx-eslint/eslint-plugin-react/blob/maste...
From what I remember, being able to pass children as a prop is considered a side-effect of an implementation detail, that breaks the expected abstraction. There really isn't any reason to use it, and I think there's a chance it may even confuse the virtual dom diffing?
Also this would prevent you from accidentally doing both at once:
Is it me?}>
-
Speeding up the JavaScript ecosystem – Polyfills gone rogue
I try to focus on the issues rather than individuals, but the root of the problems in the listed eslint plugin libraries points to ljharb.
If you do some simple digging into these libraries, you will find that these types of commits are quite common within them.
https://github.com/jsx-eslint/eslint-plugin-react/commit/e1d...
https://github.com/jsx-eslint/jsx-ast-utils/commit/bad51d062...
https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/commit/...
He would rather see the download count of these polyfill libraries https://github.com/ljharb/ljharb#projects-i-maintain increase, compared to assessing the health of the JavaScript ecosystem.
-
The Best ESLint Rules for React Projects
An obvious pick for React projects, but eslint-plugin-react along with their plugin:react/recommended rule set is a must. This will give you some sensible rules such as requiring a key to be specified in JSX arrays. eslint-config-airbnb is another good (if a bit loose) base rule set on top of eslint-plugin-react to start from.
-
Avoid "&&" Operator for Conditional Rendering in React
If you already have the eslint-plugin-react installed, you can enable the following rule.