Posts

Showing posts with the label setInterval

setTimeout and setInterval with extra arguments ... once again!

Funny discussion today on twitter about " why on Earth IE still does not support extra arguments with setTimeout and setInterval " ... oh, well ... The execScript Behaviour Somebody in IE team thinks that the rest of the world should avoid extra arguments because of a bloody edge case as the third argument in IE is: // ... seriously ... setTimeout("Msgbox('WTF')", 0, "VBScript"); What IE Users Could Do Well, rather than create a closure every bloody time we would like to reuse a function with different arguments, something posible 10 years ago via ActionScript 1, every web developer (and not only) misses the opportunity to avoid closures using a de-facto standard for some unknown reason not part yet of ECMAScript specifications. For those interested I will show an example later, right now let's think about a solution compatible with VBScript for those mental developers, as I have been, brave enough to still use this language for some purpose. ...