❯ ~/robonen/tools
core
  • stdlibapi
  • platformapi
  • fetchapi
  • encodingapi
  • crdtapi
vue
  • vueapi
  • writekitapi
    ❯
    guide
    • Introduction
    • Playground
    • ❯addMark
    • ❯applyInputRule
    • ❯chainCommands
    • ❯convertBlock
    • ❯defaultTextType
    • ❯deleteSelection
    • ❯deleteSelectionInto
    • ❯duplicateBlock
    • ❯ensureNotEmpty
    • ❯exitAtom
    • ❯focusBlock
    • ❯indentListItem
    • ❯insertBlockBeside
    • ❯insertHardBreak
    • ❯insertSliceAt
    • ❯isBlockActive
    • ❯isMarkActive
    • ❯isTextBlockType
    • ❯joinBackward
    • ❯joinForward
    • ❯landingAfter
    • ❯moveBlockDown
    • ❯moveBlocks
    • ❯moveBlockUp
    • ❯outdentListItem
    • ❯removeBlock
    • ❯removeMark
    • ❯replaceSelection
    • ❯selectAll
    • ❯selectionBlockId
    • ❯setBlockType
    • ❯splitBlock
    • ❯toggleBlockType
    • ❯toggleChecked
    • ❯toggleMark
  • primitivesui
configs
  • eslintguide
  • tsconfigguide
  • tsdownguide
infra
  • renovateguide
@robonen/writekit/defaultTextType
fn

defaultTextType

tested

The block type a fresh line gets: paragraph when registered, else the first text block.

Source Tests

Signature

ts
export function defaultTextType(state: WritekitState): string{ ... }

Parameters

ParameterTypeDefaultDescription
stateWritekitState——

Returns

string
on this page
  • Signature
  • Parameters
  • Returns