From cbbb6bf4e129db51ea2adf3d401fa908e9e87e50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20Ku=CC=88hn?= Date: Thu, 8 Apr 2021 22:17:52 +0200 Subject: [PATCH] docs: update content --- docs/src/demos/Examples/CodeBlockLanguage/index.vue | 5 +++++ docs/src/demos/Nodes/CodeBlockLowlight/index.vue | 5 +++++ docs/src/docPages/api/nodes/code-block-lowlight.md | 4 ---- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/docs/src/demos/Examples/CodeBlockLanguage/index.vue b/docs/src/demos/Examples/CodeBlockLanguage/index.vue index 89f27c01..a1e8fbfe 100644 --- a/docs/src/demos/Examples/CodeBlockLanguage/index.vue +++ b/docs/src/demos/Examples/CodeBlockLanguage/index.vue @@ -19,6 +19,11 @@ import CodeBlockComponent from './CodeBlockComponent' // install all highlight.js languages import 'lowlight' +// or install specific languages only +// import lowlight from 'lowlight/lib/core' +// import javascript from 'highlight.js/lib/languages/javascript' +// lowlight.registerLanguage('javascript', javascript) + export default { components: { EditorContent, diff --git a/docs/src/demos/Nodes/CodeBlockLowlight/index.vue b/docs/src/demos/Nodes/CodeBlockLowlight/index.vue index 2b85646f..69976deb 100644 --- a/docs/src/demos/Nodes/CodeBlockLowlight/index.vue +++ b/docs/src/demos/Nodes/CodeBlockLowlight/index.vue @@ -18,6 +18,11 @@ import CodeBlockLowlight from '@tiptap/extension-code-block-lowlight' // install all highlight.js languages import 'lowlight' +// or install specific languages only +// import lowlight from 'lowlight/lib/core' +// import javascript from 'highlight.js/lib/languages/javascript' +// lowlight.registerLanguage('javascript', javascript) + export default { components: { EditorContent, diff --git a/docs/src/docPages/api/nodes/code-block-lowlight.md b/docs/src/docPages/api/nodes/code-block-lowlight.md index 47a9a8b9..c5df20c1 100644 --- a/docs/src/docPages/api/nodes/code-block-lowlight.md +++ b/docs/src/docPages/api/nodes/code-block-lowlight.md @@ -6,10 +6,6 @@ With the CodeBlock extension you can add fenced code blocks to your documents. I Type ```  (three backticks and a space) or ∼∼∼  (three tildes and a space) and a code block is instantly added for you. You can even specify the language, try writing ```css . That should add a `language-css` class to the ``-tag. -::: warning Restrictions -The CodeBlock extension doesn’t come with styling and has no syntax highlighting built-in. It’s on our roadmap though. -::: - ## Installation ```bash # with npm