Sample dan CSS yang digunakan

CSS (Copy CSS ini ke Template)

.hljs{display:block;overflow-x:auto;padding:0.5em;background:#474949;color:#d1d9e1}
.hljs-comment,.hljs-quote{color:#969896;font-style:italic}
.hljs-keyword,.hljs-selector-tag,.hljs-literal,.hljs-type,.hljs-addition{color:#cc99cc}
.hljs-number,.hljs-selector-attr,.hljs-selector-pseudo{color:#f99157}
.hljs-string,.hljs-doctag,.hljs-regexp{color:#8abeb7}
.hljs-title,.hljs-name,.hljs-section,.hljs-built_in{color:#b5bd68}
.hljs-variable,.hljs-template-variable,.hljs-selector-id,.hljs-class .hljs-title{color:#ffcc66}
.hljs-section,.hljs-name,.hljs-strong{font-weight:bold}
.hljs-symbol,.hljs-bullet,.hljs-subst,.hljs-meta,.hljs-link{color:#f99157}
.hljs-deletion{color:#dc322f}
.hljs-formula{background:#eee8d5}
.hljs-attr,.hljs-attribute{color:#81a2be}
.hljs-emphasis{font-style:italic}

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;