oh, just looked over your code example again, loading in html, and that's not how I would suggest it by the way. I'd suggest you have 1 html file for your module, with the markup needed for it, then use jquery to modify it if you want to turn on and off a checkbox (rather than loading in 2 seperate html files).
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.
oh, just looked over your code example again, loading in html, and that's not how I would suggest it by the way. I'd suggest you have 1 html file for your module, with the markup needed for it, then use jquery to modify it if you want to turn on and off a checkbox (rather than loading in 2 seperate html files).
Just thought I'd mention that.