Closed drplauska closed 1 year ago
~That should be an easy fix, I'll get on it~
I misspoke...this seems like an esbuild issue. I'll have to investigate
thanks @okikio
@drplauska
import typeof ...
esbuild expects import
or import type ...
.js
files by default, you can enable support for it though (I think it's broken right now in bundlejs but I will enable support for it)
{
esbuild: {
loader: {
".js": "jsx"
}
}
}
react-native
and react-native-code-push
, I'll get a fix out as soon as I can but you can use this for now bundlejs result@drplauska This is now fixed e.g.
To get this to work you need this config
{
// You may want to enable the polyfill if you want a complete bundle that will work on the browser
"polyfill": false,
// JSX/TSX is no longer allowed by default to tell esbuild you can use JSX again
// you need to change this to true
"tsx": true,
"esbuild": {
"loader": {
// Esbuild will only support JSX in `.jsx` files
// this tells esbuild to allow JSX in `.js` files
".js": "jsx",
},
},
"alias": {
// For some reason `hermes-profile-transformer` package is broken and is linking to the wrong file
// so to fix that I direct it to the correct file
"hermes-profile-transformer":
"hermes-profile-transformer@0.0.6/dist/hermes-profile-transformer.esm.js",
},
}
I'll mark this as done