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
import{jsx}from'react/jsx-runtime';functionBuildbabel(props){returnjsx("div",{children: jsx("h1",{children: "Welcome to Buildbabel!"},void0)},void0);}export{Buildbabel};
functionBuildswc(props){return(/*#__PURE__*/React.createElement("div",null,/*#__PURE__*/React.createElement("h1",null,"Welcome to Buildswc!")));}export{Buildswc};
The end result of this is that apps consuming a library built with SWC as the compiler will throw React is undefined at runtime (which is how I discovered this).
I can only assume the swc instance is somehow currently not being passed the relevant config when building:
[CORRECT] Babel Project
Creation
Output
dist/libs/buildbabel/index.esm.js
[INCORRECT] SWC Project
Creation
Output
dist/libs/buildswc/index.esm.js
The end result of this is that apps consuming a library built with SWC as the compiler will throw
React is undefined
at runtime (which is how I discovered this).I can only assume the swc instance is somehow currently not being passed the relevant config when building:
This config is being explicitly wired up in the
jest.config.js
however:The text was updated successfully, but these errors were encountered: