Skip to content

Latest commit

 

History

History
48 lines (34 loc) · 892 Bytes

README.md

File metadata and controls

48 lines (34 loc) · 892 Bytes

tiptap-extension-margin

An extension that add margin to tiptap paragraph or more nodes.


NPM URL version



Install

npm install tiptap-extension-margin -S

Usage

import Margin from "tiptap-extension-margin";

const editor = new Editor({
  element: document.querySelector(".editor"),
  extensions: [StarterKit, Margin],
});

// { top, bottom, left, right }
editor.chain().focus().setMargin({ top: "10px" }).run();

Relations

tiptap: https://tiptap.dev/

tiptap-appmsg-editor: https://github.com/KID-1912/tiptap-appmsg-editor