doc_allocations.html (318B)
1 <!DOCTYPE HTML> 2 <html> 3 <head> 4 <meta charset="utf-8"> 5 </head> 6 <body> 7 <script> 8 "use strict"; 9 10 window.allocs = []; 11 window.onload = function() { 12 function allocator() { 13 for (let i = 0; i < 1000; i++) { 14 window.allocs.push({}); 15 } 16 } 17 18 window.setInterval(allocator, 1); 19 }; 20 </script> 21 </pre> 22 </body> 23 </html>