Created
January 19, 2020 07:13
-
-
Save iHTCboy/1ac5a65498efa7b323077c85e350db30 to your computer and use it in GitHub Desktop.
js代码语法高亮
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
<!-- js代码语法高亮 | |
<link rel="stylesheet" href="//cdn.bootcss.com/highlight.js/9.15.8/styles/monokai-sublime.min.css"> | |
<script src="//cdn.bootcss.com/highlight.js/9.15.8/highlight.min.js"></script> | |
<script> | |
// hljs.initHighlightingOnLoad(); | |
$(document).ready(function () { | |
$('pre code').each(function (i, block) { | |
$(this).removeClass(); | |
hljs.highlightBlock(block); | |
}); | |
}); | |
</script> | |
--> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment