更新时间:2023-10-23 08:49:22
以逗号分隔的声明只是简写.执行方面没有区别.但是,如果您声明了很多变量,它可以帮助减小javascript文件的大小.
The comma separated declaration is just a short hand. Executing-wise there's no difference. But it can help reduce the size of your javascript file if you are declaring a lot of variables.
您甚至可以:
var a = 1, b = 'string', c = new Date();