I believe Function.name or similiar is not available in Espruino.
Also a common polyfill uses function.toString() and Although Espruino does have Object.toString() which operates on a function , the returned string does not provide the name. (see attached).
Any thoughts on the possibility of implementing function.name or a workaround to get the name of a function ?
Thanks in Advance
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.
Hello,
Im looking to use Function.name in javascript. https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/name
while porting the Xstate library to Expruino.
I believe Function.name or similiar is not available in Espruino.
Also a common polyfill uses function.toString() and Although Espruino does have Object.toString() which operates on a function , the returned string does not provide the name. (see attached).
Any thoughts on the possibility of implementing function.name or a workaround to get the name of a function ?
Thanks in Advance
2 Attachments