Babel ^7.12.0 breaks preact jsx-runtime export
See original GitHub issueHi,
due to this change in babel https://github.com/babel/babel/pull/12116/commits/d6b0822ee9e95321a417b321a6687048faf1c3a1, the preact jsx runtime can’t be imported anymore. Preact exports the jsx-runtime as folder, but babel expects a file with file ending .js
now (${source}/jsx-runtime.js
and ${source}/jsx-dev-runtime.js
).
Module not found: Error: Can't resolve 'preact/jsx-runtime.js'
Is that something we should address at the babel repo, or do we need to change how the runtime is exported in preact?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Error with JSX in my React Library when Switching to Preact
IF I publish the un-babel'd code and it is simply the source cope at the top written in new ECMAScript, I get an...
Read more >React Ecosystem: Setting up Babel 7 and Webpack 5 for React
With v7, Babel introduced some breaking changes and has decided to move away from the above approach and started shipping each feature ...
Read more >Getting Started | Preact: Fast 3kb React alternative with the ...
This guide helps you get up and running to start developing Preact apps, using 3 popular options. If you're new to Preact, we...
Read more >Introducing the New JSX Transform – React Blog
Together with the React 17 release, we've wanted to make a few improvements to the JSX transform, but we didn't want to break...
Read more >preact-emotion-babel-plugin - CodeSandbox
Forked Frompreact-emotion-babel-plugin; Environmentpreact-cli. Files. src. index.js. styled.js .babelrc. package.json. sandbox.config.json. Dependencies.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Fixed in
@babel/helper-builder-react-jsx-experimental@7.12.4
I’m guessing this is something strange “craco” is doing.