Skip to content

Failed to resolve module specifier "react/jsx-runtime" #16411

Answered by hi-ogawa
Digital39999 asked this question in Q&A
Discussion options

You must be logged in to vote

I never thought that such thing could cause whole website to break

As far as I know, vite-plugin-externalize-deps is not most intuitive thing to for normal users just bundling an app. It's like telling Vite to keep import "react" in your source code instead of bundling the dependencies.

vite-plugin-externalize-deps could be convenient for developing a library where you don't want to bundle the whole react into your component library.

I don't think Remix team has ever mentioned vite-plugin-externalize-deps, so I just wonder where you got this idea from.

And also I was confused because i never actually used react/jsx-runtime so I didn't know where and how to import.

You don't normally i…

Replies: 3 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@hi-ogawa
Comment options

Answer selected by Digital39999
@Digital39999
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
3 participants
Converted from issue

This discussion was converted from issue #16401 on April 12, 2024 11:50.