benmerckx / genes

Generates split ES6 modules and Typescript definitions from Haxe modules.
43 stars 8 forks source link

$global is not defined #29

Closed benmerckx closed 3 years ago

benmerckx commented 3 years ago

Should transform

https://github.com/HaxeFoundation/haxe/blob/20fe8fb2dcbf7a49d1993404e53bd7ad19842e5b/std/js/Lib.hx#L123

kevinresol commented 3 years ago

Just hit this one too

benmerckx commented 3 years ago

Can look at it next week. In case it's pressing you can define $global somewhere or check for it here and emit the equivalent of what Haxe defines it as: https://github.com/benmerckx/genes/blob/master/src/genes/es/ExprEmitter.hx#L205