jquery - Is there a way to write javascript object array in one line? -
this question has answer here:
is there way write in 1 line?
var data = {}; data["limit"] = [1, 0]; data["where"] = [0]; data["order"] = []; data["display"] = [0];
something like
var data = {["limit"][1,0],["where"][0]...}
javascript objects can written in one-liner this:
var data = {limit: [1, 0], where: [0], order: [], display: [0]};
Comments
Post a Comment