Behseini
Behseini

Reputation: 6330

How to run highlight.js on JS Fiddle

I am working on this demo. Why am I not able to run Highcharts.js on the JS Fiddle?

$(document).ready(function() {
  $('pre code').each(function(i, e) {
    hljs.highlightBlock(e)
  });

Upvotes: 0

Views: 306

Answers (1)

tomato
tomato

Reputation: 93

You are not closing the $(document).ready(function() { call. You can view the syntax error you are getting in the developer console of your browser.

Here is a fixed code block for you:

$(document).ready(function() {
  $('pre code').each(function(i, e) {
    hljs.highlightBlock(e)
  });
 }); // this is the missing closing });

Upvotes: 1

Related Questions