开发者

Populating value using Array

开发者 https://www.devze.com 2023-02-20 07:17 出处:网络
var AppArray = [开发者_C百科{ Col1: \'asas\', Col2:\'12\' }, { Col1: \'asas2\', Col2:\'12\' }]; Why do you need this as an array if you have only one object in it.
var AppArray = [开发者_C百科{
        Col1: 'asas', Col2:'12'
      },
      {
        Col1: 'asas2', Col2:'12'
      }];


Why do you need this as an array if you have only one object in it.

you can just create an object itself instead of array and use it directly as PrimeObj.col1 and PrimeObj.col2.

var PrimeObj = {col1: 'bsbbsb', col2:'30042'};
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号