@wikifactory/slate-trailing-block

0.6.0 • Public • Published

@wikifactory/slate-trailing-block

NPM version

Slate plugin to ensure a trailing block.

Install

npm install @wikifactory/slate-trailing-block

Simple Usage

import TrailingBlock from 'slate-trailing-block'

const plugins = [
  TrailingBlock({ type: 'paragraph' })
]

Arguments

This plugin accepts options to redefine the following block types:

  • [type: String] — type for the trailing block
  • [match: Function] — function that checks against the last node

Utilities

slate-trailing-block exports utilities and changes:

changes.focusAtEnd

plugin.changes.focusAtEnd(editor: Editor) => Editor

Focus at the end of the last block.

Readme

Keywords

Package Sidebar

Install

npm i @wikifactory/slate-trailing-block

Weekly Downloads

1,895

Version

0.6.0

License

Apache-2.0

Unpacked Size

106 kB

Total Files

20

Last publish

Collaborators

  • drewler
  • salfield