Monday, 3 April 2017

javascript call stack main function

Watching this Philip Roberts talk at JSConf 2014 at this point https://youtu.be/8aGhZQkoFbQ?t=12m38s In the setTimeout execution example I see a main() function pushed in the call stack at first. What's that function? Could I have any information about it?

I indeed saw using the browser debugger there is always an anonymous function as first element of the stack. But I'm not sure it's the same thing. If so, the odd part is when the setTimeout callback is pushed in the stack: there is no main().



via alfredopacino

No comments:

Post a Comment