react-checkbox-tree icon indicating copy to clipboard operation
react-checkbox-tree copied to clipboard

Anyone getting this error? 'CheckboxTree' cannot be used as a JSX component

Open ariscruz opened this issue 9 months ago • 1 comments

Full error: 'CheckboxTree' cannot be used as a JSX component. Its instance type 'CheckboxTree' is not a valid JSX element. The types returned by 'render()' are incompatible between these types. Type 'React.ReactNode' is not assignable to type 'import Type '{}' is not assignable to type 'ReactNode'

Some details: react-checkbox-tree: "1.8.0" react: "^17.0.2" react-dom: "^17.0.2" react-types: "^17.0.37"

We're using yarn to build. Tried to downgrade react-checkbox-tree to "1.7.3" but same error.

Have looked into adding a resolutions for @types/react to 17 (similar to this: https://github.com/facebook/react/issues/24304#issuecomment-1094551986), did a cleanup of node_modules and then yarn install but error still persists

Updating to react18 is not an option yet. Appreciate your help. Thanks

ariscruz avatar May 24 '24 08:05 ariscruz