draft-js-plugins-utils

2.0.3 • Public • Published

Draft js plugin utilities

Available methods

createLinkAtSelection

createLinkAtSelection(
  editorState: EditorState,
  url: string
) => EditorState

removeLinkAtSelection

removeLinkAtSelection(
  editorState: EditorState,
) => EditorState

getCurrentEntityKey

getCurrentEntityKey(
  editorState: EditorState,
) => DraftEntityKey

getCurrentEntity

getCurrentEntity(
  editorState: EditorState,
) => DraftEntity

hasEntity

hasEntity(
  editorState: EditorState,
  entityType: DraftEntityType
) => boolean

Package Sidebar

Install

npm i draft-js-plugins-utils

Weekly Downloads

14,202

Version

2.0.3

License

MIT

Unpacked Size

7.33 kB

Total Files

8

Last publish

Collaborators

  • juliankrispel