SyntaxFix
Write A Post
Hire A Developer
Questions
Use array.push() to add an item to the end of the array.
var sample = new Array(); sample.push(new Object());
you can use it
var x = 100; var sample = []; for(let i=0; i<x ;i++){ sample.push({}) OR sample.push(new Object()) }