R
fn

setBlockType

tested

Convert the focused block to `type` (preserving inline content).

Signature

ts
export function setBlockType(type: string, attrs?: Attrs): Command{ ... }

Parameters

ParameterTypeDescription
typestring
attrs?Readonly<Record<string, import("..").AttrValue>> | undefined

Returns

Command