eslint-plugin-react rule react/no-unknown-property false negatives on all props for threejs

65 Views Asked by At

after installing the threeJS I kept having the eslint-plugin-react rule react/no-unknown-property false negatives on all props for threeJS while trying to pass props..

See error here

I tried disabling eslint-plugin-react rule, but it wasn't the best fix

/* "react/no-unknown-property": ["error", { "ignore": ["args"] }]*/

1

There are 1 best solutions below

0
Samuel Peters On

this package solved the issue for me @react-three/eslint-plugin

follow the instructions after installation

  1. installing @react-three/eslint-plugin (npm install @react-three/eslint-plugin --save-dev)
  2. Adding "plugin:@react-three/recommended" to the extend in eslintrc.cjs file
  3. adding @react-three to the list of plugin.

See solution here