Skip to content

Conversation

@weswigham
Copy link
Member

Not sure who updated the docs to imply we supported it, but we didn't, and haven't since our initial implementation of the new jsx transform. As I said in that PR, supporting it, if we'd like to, is fairly easy. Since it seems like it was assumed we did, here we are.

Fixes #59340

@typescript-bot typescript-bot added Author: Team For Milestone Bug PRs that fix a bug with a specific milestone labels Aug 1, 2024
@jakebailey
Copy link
Member

That was changed in https://github.com/microsoft/TypeScript-Website/pull/3064/files; we could just remove this line.

Not sure if something like esbuild supports this either?

@andrewbranch
Copy link
Member

Where do the values "classic" and "automatic" come from?

@jakebailey
Copy link
Member

jakebailey commented Aug 1, 2024

I actually think I just missed a typo in the docs; shouldn't they have been @jsxRuntime react and @jsxRuntime react-jsx to match the jsx config option? ("classic" and "automatic" were I think intended to be the human-readable names)

@weswigham
Copy link
Member Author

Where do the values "classic" and "automatic" come from?

They come from the babel transform.

I actually think I just missed a typo in the docs; shouldn't they have been @jsxRuntime react and @jsxRuntime react-jsx to match the jsx config option?

Nope. They're what they are to match what babel supports, nothing more, nothing less. We're not the originators of these pragmas.

@weswigham weswigham merged commit 8daac14 into microsoft:main Aug 1, 2024
@sandersn sandersn removed this from PR Backlog Apr 22, 2025
@microsoft microsoft locked as resolved and limited conversation to collaborators Oct 16, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Author: Team For Milestone Bug PRs that fix a bug with a specific milestone

Projects

None yet

Development

Successfully merging this pull request may close these issues.

jsxRuntime pragma does not work

4 participants