Colors in JavaScript console

console.log('%c Oh my heavens! ', 'background: #222; color: #bada55');
Colors in JavaScript console.png
console.log("%cStr1"+"%cStr2","CSS-for-str1","CSS-for-str2")
Colors in JavaScript console.png

你可能感兴趣的:(Colors in JavaScript console)