Highlight JS With Metalsmith and Marked

#hljs #metalsmith #marked

To get metalsmith, marked and highlight.js working together, I made the following modifications to my build files:

app.js

$(function() {
  $("pre code").addClass("hljs");
});

index.js

--snip--

.use(markdown({
  gfm: true,
  sanitize: false,
  tables: true,
  highlight: function (code) {
    return require('highlight.js').highlightAuto(code).value;
  }

--snip--