EldoranDev / gridsome-plugin-remark-shiki

Syntax highlighter for markdown code blocks using shiki
15 stars 8 forks source link

add pre tag to unknown lang fallback #22

Closed scrambldchannel closed 3 years ago

scrambldchannel commented 3 years ago

Hi

As mentioned in https://github.com/EldoranDev/gridsome-plugin-remark-shiki/issues/21, here's a PR to show what I'm referring to. Let me know if I'm missing something obvious.

Note, I changed this to use shiki to render the HTML using 'txt' as a fallback which I think is a bit cleaner than my original solution.

Cheers Alex :)

EldoranDev commented 3 years ago

I really like the txt as fallback. If shiki allows the use of txt I'll add that aswell but for now this looks good.

If you remove the escape function in your PR the checks should pass and I'll merge this.

scrambldchannel commented 3 years ago

Cool, I didn't see that it had failed, sorry about that. I've removed the function and it seems to pass now.

Cheers Alex