wooorm / refractor

Lightweight, robust, elegant virtual syntax highlighting using Prism

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Prism is running on page load

tamagokun opened this issue · comments

when the page loads, it seems like Prism gets run across the entire page. Is there a way to work around this?

Seems like if it gets loaded in page, it will run "highlightAll" unless Prism.manual is set to true.

https://github.com/PrismJS/prism/blob/gh-pages/components/prism-core.js#L505-L522

commented

So, from what I’m reading, we must set window.Prism = {manual: true} to turn this off?

Would you be interested in a tested PR for this?

totally. PR coming up.