However that doesn't contain all the info - for instance if you wrote your own tool to look at the JSON comments in the wrappers, you could determine what was definitely supposed to be an integer/float/etc.
Having said all that, have you tried running TypeScript-compiled code yet? There was an issue posted up a week or so ago - in that case the TypeScript compiler that was being used created code where functions are used before they're declared.
That's fine in normal JS where everything is parsed beforehand, but in Espruino it's parsed as it is executed, so 'Function Hoisting' doesn't work. To get code working in that case you'd ideally need to flip some setting in the transpiler to make it generate code for functions in an order that doesn't rely on the hoisting.
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.
Hi,
I'm afraid there aren't any definitions around, although it would be easy enough to extract the information from the Espruino build process. All the functions are described in 'wrapper files': https://github.com/espruino/Espruino/blob/master/README_BuildProcess.md#wrapper-files-
For instance there's a type file for Tern's autocomplete in the Web IDE: http://www.espruino.com/json/espruino.json
However that doesn't contain all the info - for instance if you wrote your own tool to look at the JSON comments in the wrappers, you could determine what was definitely supposed to be an integer/float/etc.
Having said all that, have you tried running TypeScript-compiled code yet? There was an issue posted up a week or so ago - in that case the TypeScript compiler that was being used created code where functions are used before they're declared.
That's fine in normal JS where everything is parsed beforehand, but in Espruino it's parsed as it is executed, so 'Function Hoisting' doesn't work. To get code working in that case you'd ideally need to flip some setting in the transpiler to make it generate code for functions in an order that doesn't rely on the hoisting.