Type ‘T’ does not satisfy the constraint ‘keyof IntrinsicElements | JSXElementConstructor’.

The solution for “Type ‘T’ does not satisfy the constraint ‘keyof IntrinsicElements | JSXElementConstructor’.” can be found here. The following code will assist you in solving the problem.

// If you tried to use the generics with React.ComponentProps
// Then this is a working example for you

function myFunction>
(Component: T, props: React.ComponentProps {
// implementation
}

// You must extend the T otherwise you will get this error you are searching on google right now

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

0
inline scripts encapsulated in