const language = this.converstaionLanguage; // {"lang":"en"} <- this is JSON
console.log(language); // [object Object]
console.log(JSON.stringify(language) // {"lang":"en"}
const obj={
firstName: 'John',
lastName: 'MacDonald',
age: 32,
pets: true
};
console.log(obj); // {firstName: 'John', lastName: 'MacDonald', age: 32, pets: true}
console.log(`${obj}`); // [object Object]
console.log(`${JSON.stringify(obj)}`); // {"firstName":"John","lastName":"MacDonald","age":32,"pets":true}
console.log(Object.keys(obj)); // ['firstName', 'lastName', 'age', 'pets']
console.log(Object.values(obj)); // [ 'John', 'MacDonald', 32, true ]
let object = { x: 0 };
let number = 10;
let string = "hello world";
console.log(object);
console.log(number);
console.log(string);
console.log(Object.getOwnPropertyNames(Math));
//-> ["E", "LN10", "LN2", "LOG2E", "LOG10E", "PI", ...etc ]
console.log(Object.getOwnPropertyNames(Math).filter(function (p) {
return typeof Math[p] === 'function';
}));
//-> ["random", "abs", "acos", "asin", "atan", "ceil", "cos", "exp", ...etc ]