fn
setBlockType
testedConvert the focused block to `type` (preserving inline content).
Signature
ts
export function setBlockType(type: string, attrs?: Attrs): Command{ ... }Parameters
| Parameter | Type | Description |
|---|---|---|
type | string | — |
attrs? | Readonly<Record<string, import("..").AttrValue>> | undefined | — |
Returns
Command