Thanks for posting it up!
You might find you can add:
Object.keys(global).forEach(function(n) { if (n!="onInit" && n!="reset") delete global[n]; });
To remove most of the other things that might have got defined before?
@Gordon started
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Thanks for posting it up!
You might find you can add:
To remove most of the other things that might have got defined before?