fixed haxe3 compilation in js