Type error cannot be used as a JSX component
#1013
-
If I have a Next.js app, then do Is this library not supposed to be used inside of another Next.js application? |
Beta Was this translation helpful? Give feedback.
Answered by
corysimmons
Nov 1, 2023
Replies: 1 comment
-
I was running into this in a monorepo too. It seems its not able to find the React types. This fixed it: https://stackoverflow.com/a/75093164/175825 My tsconfig for that dir: {
"compilerOptions": {
"jsx": "preserve",
"paths": {
"react": [ "./node_modules/@types/react" ]
}
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
corysimmons
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was running into this in a monorepo too. It seems its not able to find the React types. This fixed it: https://stackoverflow.com/a/75093164/175825
My tsconfig for that dir: