@Gordon Why would require()ing a module from SD and executing its handler/callback be a bad idea? My thinking was that loading code on-demand and unloading it when done would be better than having everything in memory at all times. One would be able to have a lot more dynamic pages than would otherwise fit in Espruino's memory. Each module would of course have to be small enough to fit in memory when loaded.
Or were you thinking of latency, energy consumption or some other factor?
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.
@Gordon Why would
require()
ing a module from SD and executing its handler/callback be a bad idea? My thinking was that loading code on-demand and unloading it when done would be better than having everything in memory at all times. One would be able to have a lot more dynamic pages than would otherwise fit in Espruino's memory. Each module would of course have to be small enough to fit in memory when loaded.Or were you thinking of latency, energy consumption or some other factor?