tiptap/docs/api/marks/text-style.md
2021-11-09 11:56:27 +01:00

1.1 KiB
Raw Blame History

description icon
Useless extension, just adds <span> tags (required by other extensions though). palette-line

TextStyle

Version Downloads

This mark renders a <span> HTML tag and enables you to add a list of styling related attributes, for example font-family, font-size, or color. The extension doesnt add any styling attribute by default, but other extensions use it as the foundation, for example FontFamily or Color.

Installation

npm install @tiptap/extension-text-style

Commands

removeEmptyTextStyle()

Remove <span> tags without an inline style.

editor.command.removeEmptyTextStyle()

Source code

packages/extension-text-style/

Usage

https://embed.tiptap.dev/preview/Marks/TextStyle