Skip to content

Commit

Permalink
Update 2.configuration.md
Browse files Browse the repository at this point in the history
Update highlight.preload config for adding new grammars to match current Shiki version.
  • Loading branch information
ashour committed Oct 24, 2023
1 parent e5d0029 commit 79b88be
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions docs/content/1.get-started/2.configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -238,17 +238,9 @@ export default defineNuxtConfig({
content: {
highlight: {
preload: [
{
id: 'gdscript',
scopeName: 'source.gdscript',
aliases: ['gdscript', 'gd'], // Use to mark code blocks in Markdown
grammar: JSON.parse(
readFileSync(
// Place the language grammar file somewhere in your project
'./shiki/languages/gdscript.tmLanguage.json'
).toString()
),
},
JSON.parse(
readFileSync('./shiki/languages/gdscript.tmLanguage.json', 'utf-8'),
),
],
},
},
Expand Down

0 comments on commit 79b88be

Please sign in to comment.