EldoranDev / gridsome-plugin-remark-shiki

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

min theme not supported #6

Closed Berkmann18 closed 5 years ago

Berkmann18 commented 5 years ago

While trying out some themes on https://github.com/Berkmann18/gridsome-starter-netlify-netlifycms-tailwindcss, I encountered this error:

An error occurred while executing page-query for src/templates/Post.vue

Error: No theme min found

GraphQL request (6:5)
5:     date(format: "MMM D YYYY")
6:     timeToRead
       ^
7:     tags

I tried with the default theme (nord, even when I explicitly specified it) which worked but the min theme doesn't.

EldoranDev commented 5 years ago

Try to use "min-light" or "min-dark".

Berkmann18 commented 5 years ago

Both work although they produce a dark looking code block with what seems to be highlighting issues.

With mini-dark: mini-dark With mini-light: mini-light

EldoranDev commented 5 years ago

I'll look into that.

could you send me the code block you use or point me to the repository ?

Berkmann18 commented 5 years ago

Sure, here's the repo as off before trying the min-light/min-dark.

The code block in the images above can be found here.

EldoranDev commented 5 years ago

okay, to fix the syntax highlighting you'll have to switch to vue / vue-htm instead of javascript as language.

Why the background is wrong I'll have to investigate, I'll look into it as fast as I can.

Berkmann18 commented 5 years ago

Okay, I've tried vue and vue-htm and vue-html seems to highlight things properly (compared to vue which does it except for <page-query>).

EldoranDev commented 5 years ago

Sorry for the long wait.

To fix this issue just remove the background styles from tailwind that get added in your Post.vue Line 74 and 77. This should fix your styling problem.

Page Query will not be highlighted in the near future, will have to check if shiki or this plugin can incoperate the custom syntax generation from vetur.