Javascript Error logging

console.error(error.message);

or simply 
console.log(error.message);
aashish-cd