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
TypeScript 4.1 supports React 17’s upcoming jsx and jsxs factory functions through two new options for the jsx compiler option:
react-jsx
react-jsxdev
These options are intended for production and development compiles respectively. Often, the options from one can extend from the other. For example, a tsconfig.json for production builds might look like the following:
Is your proposal related to a problem?
TypeScript 4.1 supports React 17's new JSX factories:
Describe the solution you'd like
The default
jsx
transform in TypeScript should bereact-jsxdev
. Only when runningreact-scripts build
it should bereact-jsx
.Describe alternatives you've considered
Additional context
Related issues:
Background information:
The text was updated successfully, but these errors were encountered: