one can also include bits of javascript (see libs/js) and run it from init method
This will however run on every boot, not once per DFU update. You could however create some marker file in the storage after first run so it is not run again.
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.
you can include your own library with init code, see e.g one for microbit https://github.com/espruino/Espruino/blob/master/libs/microbit/jswrap_microbit.c#L144 or banglejs https://github.com/espruino/Espruino/blob/master/libs/banglejs/jswrap_bangle.c#L3202
one can also include bits of javascript (see libs/js) and run it from init method
This will however run on every boot, not once per DFU update. You could however create some marker file in the storage after first run so it is not run again.