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
We basically need s/JSX.Element/React.JSX.Element to fix this. There are two occurrences in this repo itself, for which I will send a PR. Though this requires updating to v18 typings first.
But most of the JSX.Element occurrences seem to come from the build process, which materializes types that were previously not spelled out explicitly.
The text was updated successfully, but these errors were encountered:
The dist/ directories aren't committed to this Git repository. But my current understanding is that they are part of the NPM package, so they're not built on the library user's machine, but on the library maintainer's machine when building the release.
When I clone the repo and run yarn install, I get the correct typings already:
Given that the yarn.lock should fix all the versions, it's not clear to me why I get a different result than what's released.
@clauderic I assume it's GitHub Actions like this one that build the releases. Just as another data point, on your own machine, do you get React.JSX.Element or JSX.Element? Then we can compare how the environments differ to figure out how we can get the release environment to produce the new-style typings.
Philipp91
changed the title
With React 91 typings: Cannot find namespace 'JSX'.
With React 19 typings: Cannot find namespace 'JSX'.
Dec 7, 2024
I previously posted about this here, but I don't want to spam that thread.
We basically need
s/JSX.Element/React.JSX.Element
to fix this. There are two occurrences in this repo itself, for which I will send a PR. Though this requires updating to v18 typings first.But most of the
JSX.Element
occurrences seem to come from the build process, which materializes types that were previously not spelled out explicitly.The text was updated successfully, but these errors were encountered: