wait for highlighter.js to finish running