• Ahh - you're calling the function once, and then asking Espruino to call the function again with E.on('init',. I don't think that's really a bug.

    As you're executing the file from flash, you might as well just remove the E.on('init', startApp); line, since when your app starts is run it's going to call startApp(); anyway.

    E.on('init', and the onInit function are really there for other Espruino devices where you can develop the app in RAM and then type save() to effectively 'hibernate' your app to flash memory. Then when your app 'wakes' the E.on('init' gets called - but that's not something we do on Bangle.js. There's a bit of info on that at https://www.espruino.com/Saving

About

Avatar for Gordon @Gordon started