Documentation

Verify an extension

Check the command, HTML round trip, JSON, and undo before using a new extension in your app.

Check the extension

  1. In the inline-format example, select Friday and click Highlight. Check that the HTML includes <mark>Friday</mark>.
  2. Call editor.history.undo() and check that the original text returns. Apply the highlight again with editor.history.redo().
  3. Read the HTML with getHTML(), then load it with setHTML() in an editor with the same extension list. Check that the <mark> tag and the highlight type in getJSON() survive. For an extension with attributes, check their values too.