You're right that the callbacks were described in the docs as having multiple parameters. I think I'm going to keep the single object param implementation and change the docs because that is more generic. It makes it easier to have a single event handler function for different events and it make is easier to add/remove info in other implementations without upsetting the entire function signature.
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're right that the callbacks were described in the docs as having multiple parameters. I think I'm going to keep the single object param implementation and change the docs because that is more generic. It makes it easier to have a single event handler function for different events and it make is easier to add/remove info in other implementations without upsetting the entire function signature.