function properties javascript example
Example 1: function inside object javascript
var obj = {
func: function(a, b) {
return a * b;
}
};
obj.func(3, 6); // 18
Example 2: object object javascript
person = {
'name':'john smith'
'age':41
};
console.log(person);
//this will return [object Object]
//use
console.log(JSON.stringify(person));
//instead