Horizontal Rule
The horizontalRule
node is used to represent a thematic break in the document, typically rendered as a horizontal line.
import {
} from 'prosekit/extensions/horizontal-rule' const defineHorizontalRule function defineHorizontalRule(): HorizontalRuleExtension
= extension const extension: HorizontalRuleExtension
() defineHorizontalRule function defineHorizontalRule(): HorizontalRuleExtension
. editor const editor: Editor<HorizontalRuleExtension>
. commands
Editor<HorizontalRuleExtension>.commands: ToCommandAction<{ insertHorizontalRule: []; }>
All {@link CommandAction } s defined by the editor.() insertHorizontalRule
insertHorizontalRule: CommandAction () => boolean
Execute the current command. Return `true` if the command was successfully executed, otherwise `false`.
Type three hyphens (---
) on an empty line. This will automatically create a horizontal rule.