4 ms·
So JSX is not enabled by default, right?
by msoad 11y ago
So JSX is not enabled by default, right?
- WorldMaker 11y agoYou have to use the .TSX filename extension to enable it.
- evmar 11y agoI was just playing with this today. I didn't realize it was so new! I filed a bug about the extension with the related emacs mode and it's already fixed: https://github.com/fxbois/web-mode/issues/585 https://github.com/fxbois/web-mode/issues/585
- jnetterf 11y agoYou also need to set {"jsx": "react"} (for valid JS output) or {"jsx": "preserve"} (for JSX output) in your tsconfig.json / cli options.