mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-11 07:12:29 +02:00
support 'text' language for no syntax highlighting (#875)
This commit is contained in:
parent
75538395be
commit
a6db22b6ff
1 changed files with 3 additions and 0 deletions
|
@ -28,6 +28,9 @@ class MarkdownRenderer {
|
||||||
highlight(str, lang) {
|
highlight(str, lang) {
|
||||||
lang =
|
lang =
|
||||||
lang || (siteConfig.highlight && siteConfig.highlight.defaultLang);
|
lang || (siteConfig.highlight && siteConfig.highlight.defaultLang);
|
||||||
|
if (lang === 'text') {
|
||||||
|
return str;
|
||||||
|
}
|
||||||
if (lang) {
|
if (lang) {
|
||||||
try {
|
try {
|
||||||
if (
|
if (
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue