unsetAllMarks command
unsetAllMarks will remove all marks from the current selection. By default, it respects the clearable option on each mark — marks with clearable: false will not be removed.
Parameters
options?: Record<string, any>
ignoreClearable?: boolean- Iftrue, removes all marks regardless of theirclearablesetting. Defaults tofalse
Using the unsetAllMarks command
// removes all marks that have clearable: true (default behavior)
editor.commands.unsetAllMarks()
// removes all marks, ignoring the clearable option
editor.commands.unsetAllMarks({ ignoreClearable: true })