Skip to content

Editor.js

Editor.js is an embeddable editor that returns a document as a list of content blocks.

Visit Editor.js

What does someone get when you add Editor.js?

They get an editor for separate blocks of content. Add the tools you need for blocks such as lists or images. Each block tool contributes its own editing controls and data format. Choose a small set your app can reliably show after saving.

What should your app save so an article reopens?

Save the JSON returned by Editor.js, including the block type keys. Those keys match the names in your app’s tool configuration. If you rename the key for a quote, old articles still use the earlier name. Keep a way to read the old type or convert it deliberately.

What do you need to publish or move the saved writing?

Decide how your app will display or convert each saved block. An image block may hold a file URL. Keep the actual uploaded file and its access rules separately. The core is Apache 2.0-licensed. Review the tools you install for their own license and setup requirements.

How would you plan a customer story with two block types?

Draw a fictional customer story with a quote and a photo. No uploads or editor setup are needed.

  1. Label what you save
    Give the quote and image separate type names. Mark the photo file as a separate item from the article.
  2. Label what a reader sees
    Sketch a display for each block. Decide what to show if the photo is unavailable or the destination has no equivalent quote block.