danielkellyio/awake-template

Code block syntax highlighting is not working

Closed this issue · 1 comments

https://testpygj.netlify.app/built-for-speed/

I posted some code snippets and used code block for syntax highlight and dark background. but it doesn't seem to be working. I see plan code block(no syntax highlight) with a grey background. in fact in the preview, it is the same(I mean no syntax highlighting) but in the editor, I can see the desired behaviour. (See the attached screenshot for the reference)
I tried markdown code formatting as well, but no luck.

Screen Shot 2020-04-25 at 12 28 32 AM

Syntax highlighting is not supported in the open source version. (FYI, it will be in the premium version though that hasn't been released yet). It's actually pretty easy to implement though (I had it in the open source version at one point but removed it for the sake of performance).

thecomponents/Markdown.vue component powers markdown as it's shown on the frontend in. It uses the markdown-it library. You should be able to use the markdown-it docs to implement highlighting.

Let me know if you run into any issues. Thanks!