add highlight option for demos

This commit is contained in:
Philipp Kühn
2020-08-12 09:37:15 +02:00
parent 6d1a333171
commit eeac0fce37
8 changed files with 76 additions and 15 deletions

View File

@@ -6,7 +6,7 @@ In its basic version tiptap comes very raw. There is no menu, no buttons, no sty
Lets start to add your first button to the editor.
<demo name="SimpleMenuBar" />
<demo name="SimpleMenuBar" highlight="5-11" />
Once initiated the editor has a powerful API. So called commands allow you to modify the text. In this example `this.editor.commands.bold` marks the selected text bold. There a ton of other commands (see the [list of available commands](/commands/)) and you can even chain them to do multiple things at once.
@@ -18,7 +18,7 @@ You are free to choose which parts of tiptap you want to use. Tiptap has support
Note that `Document`, `Paragraph` and `Text` are required. Otherwise you wont be able to add any plain text.
<demo name="ExtensionConfiguration" />
<demo name="ExtensionConfiguration" highlight="10-13,30-33" />
Thats also the place where you can register custom extensions, which you or someone else built for tiptap.