Skip to content
ФреймворкJavaScript

Зачёркивание: зачёркнутый текст

Wraps selected text in `<s>`. Activated with Cmd/Ctrl+Shift+S or by clicking the S button in the inline toolbar.

Импорт

TypeScript
import { Strikethrough } from '@bloklabs/core/tools';

Формат данных

TypeScript
// Stored as HTML inside the block's text field.
// "Hello <s>world</s>"
JSON
{
  "type": "paragraph",
  "data": { "text": "Hello <s>world</s>" }
}

Пример использования

TypeScript
import { Blok } from '@bloklabs/core';
import { Strikethrough } from '@bloklabs/core/tools';

const editor = new Blok({
  holder: 'editor',
  tools: {
    strikethrough: Strikethrough,
  },
});