From 714b790f0ed1dc473777d9c5b2bc9d2a95ed4519 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Weber?= Date: Thu, 23 Sep 2021 21:46:32 +0200 Subject: [PATCH] docs: block code doesn't always has a background #100 --- exampleSite/config.toml | 1 + exampleSite/content/cont/syntaxhighlight.en.md | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 54c4a9d3b4..a505296ee6 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -27,6 +27,7 @@ relativeURLs = true [markup] [markup.highlight] style = "monokai" + guessSyntax = true [markup.goldmark.renderer] unsafe= true diff --git a/exampleSite/content/cont/syntaxhighlight.en.md b/exampleSite/content/cont/syntaxhighlight.en.md index b4f88b0ea9..60c0d1d814 100644 --- a/exampleSite/content/cont/syntaxhighlight.en.md +++ b/exampleSite/content/cont/syntaxhighlight.en.md @@ -49,12 +49,13 @@ Renders to: Hugo comes with a [remarkable list](https://gohugo.io/content-management/syntax-highlighting/#list-of-chroma-highlighting-languages) of supported languages. -## Configuration +## Recommended configuration You can choose a color theme from the [list of supported themes](https://xyproto.github.io/splash/docs/all.html) and add it in your `config.toml` ````toml [markup] [markup.highlight] - style = "monokai" + style = "monokai" # choose a color theme or create your own + guessSyntax = true # avoid unstyled code if no language was given ````