Sample dan CSS yang digunakan

CSS (Copy CSS ini ke Template)

.hljs{display:block;overflow-x:auto;padding:0.5em;background:#1d1f21}
.hljs::selection,.hljs span::selection{background:#373b41}
.hljs::-moz-selection,.hljs span::-moz-selection{background:#373b41}
.hljs{color:#c5c8c6}
.hljs-title,.hljs-name{color:#f0c674}
.hljs-comment,.hljs-meta,.hljs-meta .hljs-keyword{color:#707880}
.hljs-number,.hljs-symbol,.hljs-literal,.hljs-deletion,.hljs-link{color:#c66}
.hljs-string,.hljs-doctag,.hljs-addition,.hljs-regexp,.hljs-selector-attr,.hljs-selector-pseudo{color:#b5bd68}
.hljs-attribute,.hljs-code,.hljs-selector-id{color:#b294bb}
.hljs-keyword,.hljs-selector-tag,.hljs-bullet,.hljs-tag{color:#81a2be}
.hljs-subst,.hljs-variable,.hljs-template-tag,.hljs-template-variable{color:#8abeb7}
.hljs-type,.hljs-built_in,.hljs-builtin-name,.hljs-quote,.hljs-section,.hljs-selector-class{color:#de935f}
.hljs-emphasis{font-style:italic}.hljs-strong{font-weight:bold}

Contoh HTML, XML

<!DOCTYPE html>
<title>Title</title>

<style>body {width: 500px;}</style>

<script type="application/javascript">
  function $init() {return true;}
</script>

<body>
  <p checked class="title" id='title'>Title</p>
  <!-- here goes the rest of the page -->
</body>

Contoh JavaScript

function $initHighlight(block, cls) {
  try {
    if (cls.search(/\bno\-highlight\b/) != -1)
      return process(block, true, 0x0F) +
             ` class="${cls}"`;
  } catch (e) {
    /* handle exception */
  }
  for (var i = 0 / 2; i < classes.length; i++) {
    if (checkCondition(classes[i]) === undefined)
      console.log('undefined');
  }

  return (
    <div>
      <web-component>{block}</web-component>
    </div>
  )
}

export  $initHighlight;