cljsrn

hadils 2023-02-15T13:31:10.241139Z

Hi all! I am stumped with this problem: I am using Expo 48 beta, Krell. I am trying to get transpiling (babel) to work but I keep running into these problems:

ERROR  Could not evaluate  [SyntaxError: 16:150:';' expected]
 ERROR  Could not evaluate  [TypeError: Cannot read property 'getLogger' of undefined]
 ERROR  Could not evaluate  [ReferenceError: Property '$jscomp' doesn't exist]
 
I don’t know the proper configuration of babel and build.edn to get this to work. I appreciate any help you can give me.

joshmiller 2023-02-15T22:14:22.182229Z

@hadilsabbagh18 You probably have the Hermes engine enabled, which can’t handle ES6 JS syntax

joshmiller 2023-02-15T22:14:56.409299Z

There’s a guide here for enabling/disabling it: https://reactnative.dev/docs/hermes

joshmiller 2023-02-15T22:16:03.286469Z

Better link straight to disabling: https://reactnative.dev/docs/hermes#switching-back-to-javascriptcore

hadils 2023-02-15T22:48:09.025299Z

Thank you @joshmiller

👍 1
hadils 2023-03-22T19:13:05.252719Z

Hi @joshmiller just out of curiosity, is there a way to get es6 to work with Hermes? Perhaps with babel?

joshmiller 2023-03-22T19:15:38.160039Z

I would imagine if you can transpile es6 to es5, then Hermes will handle the result, but I haven’t tried it. Others have had luck using Hermes by just setting their CLJS compiler to output es5 instead of es6; I personally just turned off Hermes because the benefits weren’t useful for me in the first place.

hadils 2023-03-22T19:16:24.571689Z

Thank you @joshmiller

👍 1