Created
April 16, 2016 10:50
-
-
Save lkLeonov/56f423b4bf8567f069182e3d76bdd865 to your computer and use it in GitHub Desktop.
Simple Chrome console styling function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Styling Chrome Console | |
function cons(styles) { | |
if (!cons.initial) cons.initial = console; | |
var defaultStyles = 'font-family: Arial; font-size: 2em;'; | |
styles = styles || defaultStyles; | |
console = { | |
log: function(str) { cons.initial.log('%c' + str, styles) } | |
} | |
}; | |
cons('font-family: Palace Script MT; font-size: 5em') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment