Changes to make the compiler outputted JS work