You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When settings "jsxImportSource": "@compiled/react", in tsconfig.json, ReactNode becomes an invalid component return type.
To Reproduce
Steps to reproduce the behavior:
constComponentA=(): React.ReactNode=>{return<div></div>;};constComponentB=(): React.ReactNode=>{return(<div><ComponentA/>
^^^^^^
'ComponentA' cannot be used as a JSX component.
Its return type 'ReactNode' is not a valid JSX element.ts(2786)
const ComponentA: () =>React.ReactNode</div>);};
Expected behavior
Align with the React types. ReactNode is a valid return type.
Screenshots
The text was updated successfully, but these errors were encountered:
Describe the bug
When settings
"jsxImportSource": "@compiled/react",
in tsconfig.json, ReactNode becomes an invalid component return type.To Reproduce
Steps to reproduce the behavior:
Expected behavior
Align with the React types. ReactNode is a valid return type.
Screenshots
The text was updated successfully, but these errors were encountered: