Javascript examples for DOM:Key Event
Check Different variable scoping using "let" keyword between browsers
<html> <head> <meta name="viewport" content="width=device-width"> </head> <body> <script> var obj = {/*from www. j a v a2s.com*/ key: 'val', key2: 'val' }; function x(b) { setTimeout(b, 1000); } var keys = Object.keys(obj); for (let ki of keys) { x(function() { console.log(ki); }); } </script> </body> </html>