fix(editor): add missing dependencies for commands
This commit is contained in:
@ -46,6 +46,9 @@ import CharacterCount from '@tiptap/extension-character-count'
|
||||
import StarterKit from '@tiptap/starter-kit'
|
||||
import {EditorContent, useEditor, VueNodeViewRenderer} from '@tiptap/vue-3'
|
||||
|
||||
import Commands from './commands'
|
||||
import suggestion from './suggestion'
|
||||
|
||||
// load all highlight.js languages
|
||||
import {lowlight} from 'lowlight'
|
||||
|
||||
@ -199,6 +202,10 @@ const editor = useEditor({
|
||||
// return VueNodeViewRenderer(CodeBlock)
|
||||
// },
|
||||
// }).configure({ lowlight }),
|
||||
|
||||
Commands.configure({
|
||||
suggestion,
|
||||
}),
|
||||
],
|
||||
onUpdate: () => {
|
||||
// HTML
|
||||
|
@ -1,6 +1,8 @@
|
||||
import { Extension } from '@tiptap/core'
|
||||
import Suggestion from '@tiptap/suggestion'
|
||||
|
||||
// Copied and adjusted from https://github.com/ueberdosis/tiptap/tree/252acb32d27a0f9af14813eeed83d8a50059a43a/demos/src/Experiments/Commands/Vue
|
||||
|
||||
export default Extension.create({
|
||||
name: 'commands',
|
||||
|
Reference in New Issue
Block a user