What are differences and when to use the following ways to create object?
var Obj ={
foo(){}
}
var Obj ={
foo:function(){}
}
What are differences and when to use the following ways to create object?
var Obj ={
foo(){}
}
var Obj ={
foo:function(){}
}