I figured out the issue.
Modules as functions cant be ticked. If its unticked it works fine, if it doesnt, then it comes up with an error regarding $jscomp.initSymbol or $jscomp.makeIterator.
If I use closure compiler to minify my code, these variables are not part of the code, which confused me, but when I did a dump() I could see that these variables were in the code that was uploaded, and were causing problems. Since unchecking the modules as functions box its stopped producing the error and allows my code to execute.
According to the webIDE this function is still in BETA, so I'm not sure if this feedback will be useful in order to fix it for upcoming releases.
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.
I figured out the issue.
Modules as functions cant be ticked. If its unticked it works fine, if it doesnt, then it comes up with an error regarding $jscomp.initSymbol or $jscomp.makeIterator.
If I use closure compiler to minify my code, these variables are not part of the code, which confused me, but when I did a dump() I could see that these variables were in the code that was uploaded, and were causing problems. Since unchecking the modules as functions box its stopped producing the error and allows my code to execute.
According to the webIDE this function is still in BETA, so I'm not sure if this feedback will be useful in order to fix it for upcoming releases.