All Projects → codex-team → Editor.js

codex-team / Editor.js

Licence: apache-2.0
A block-styled editor with clean JSON output

Programming Languages

javascript
184084 projects - #8 most used programming language
typescript
32286 projects
HTML
75241 projects
CSS
56736 projects

Projects that are alternatives of or similar to Editor.js

Rich Markdown Editor
The open source React and Prosemirror based markdown editor that powers Outline. Want to try it out? Create an account:
Stars: ✭ 2,468 (-85.53%)
Mutual labels:  editor, wysiwyg
Flutter Quill
Rich text editor for Flutter
Stars: ✭ 177 (-98.96%)
Mutual labels:  editor, wysiwyg
Pell
📝 the simplest and smallest WYSIWYG text editor for web, with no dependencies
Stars: ✭ 11,653 (-31.7%)
Mutual labels:  editor, wysiwyg
Phaser3 Particle Editor
A flexible editor for building phaser particles.
Stars: ✭ 131 (-99.23%)
Mutual labels:  editor, wysiwyg
Vditor
♏ 一款浏览器端的 Markdown 编辑器,支持所见即所得(富文本)、即时渲染(类似 Typora)和分屏预览模式。An In-browser Markdown editor, support WYSIWYG (Rich Text), Instant Rendering (Typora-like) and Split View modes.
Stars: ✭ 3,773 (-77.89%)
Mutual labels:  editor, wysiwyg
Ngx Quill Example
demo app for the advanced usage of ngx-quill module
Stars: ✭ 137 (-99.2%)
Mutual labels:  editor, wysiwyg
Lite Editor
A Modern WYSIWYG Editor especially for inline elements
Stars: ✭ 169 (-99.01%)
Mutual labels:  json, wysiwyg
Object Editor React
Schema-aware editor for structured JSON objects (drop-in React component)
Stars: ✭ 104 (-99.39%)
Mutual labels:  json, editor
Swagger Toolbox
💡 Swagger schema model (in yaml, json) generator from json data
Stars: ✭ 194 (-98.86%)
Mutual labels:  json, editor
Bridge.
Minecraft Add-on Editor | We strive to provide the best development experience possible
Stars: ✭ 193 (-98.87%)
Mutual labels:  json, editor
Swiftlatex
SwiftLaTeX, a WYSIWYG Browser-based LaTeX Editor
Stars: ✭ 1,664 (-90.25%)
Mutual labels:  editor, wysiwyg
React Json Editor Ajrm
A modular, easy to use, react component, to view, edit, and debug javascript objects.
Stars: ✭ 211 (-98.76%)
Mutual labels:  json, editor
Django Tinymce4 Lite
TinyMCE 4 editor widget for Django
Stars: ✭ 121 (-99.29%)
Mutual labels:  editor, wysiwyg
Cl Editor
Lightweight text editor built with svelte, typescript
Stars: ✭ 148 (-99.13%)
Mutual labels:  editor, wysiwyg
Awesome Wysiwyg
A curated list of awesome WYSIWYG editors.
Stars: ✭ 1,801 (-89.44%)
Mutual labels:  editor, wysiwyg
Smarteditor2
Javascript WYSIWYG HTML editor
Stars: ✭ 162 (-99.05%)
Mutual labels:  editor, wysiwyg
Kaizen Openapi Editor
Eclipse Editor for the Swagger-OpenAPI Description Language
Stars: ✭ 97 (-99.43%)
Mutual labels:  json, editor
Tinymce
The world's #1 JavaScript library for rich text editing. Available for React, Vue and Angular
Stars: ✭ 10,179 (-40.34%)
Mutual labels:  editor, wysiwyg
Tui.editor
🍞📝 Markdown WYSIWYG Editor. GFM Standard + Chart & UML Extensible.
Stars: ✭ 14,016 (-17.85%)
Mutual labels:  editor, wysiwyg
Editor
A new type of WYSIWYG editor for Kirby
Stars: ✭ 209 (-98.77%)
Mutual labels:  editor, wysiwyg

Backers on Open Collective Sponsors on Open Collective Join the chat at https://gitter.im/codex-team/editor.js

IE / Edge
IE / Edge
Firefox
Firefox
Chrome
Chrome
Safari
Safari
iOS Safari
iOS Safari
Opera
Opera
Edge 12+ Firefox 18+ Chrome 49+ Safari 10+ Safari 10+ Opera 36+

If you like a project 💗💗💗

If you like Editor.js you can support project improvements and development of new features with a donation to our collective.

👉 https://opencollective.com/editorjs

Sponsors

Support us by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]

Backers

Thank you to all our backers! 🙏 [Become a backer]

Contributors

This project exists thanks to all the people who contribute.

We really welcome new contributors. If you want to make some code with us, please take a look at the Good First Tasks. You can write to us on [email protected] or via special Telegram chat, or any other way.

Documentation

Please visit https://editorjs.io/ to view all documentation articles.

You can join a Gitter-channel or Telegram-chat and ask a question.

Changelog

See the whole Changelog

How to use Editor.js

Basics

Editor.js is a Block-Styled editor. Blocks are structural units, of which the Entry is composed. For example, Paragraph, Heading, Image, Video, List are Blocks. Each Block is represented by Plugin. We have many ready-to-use Plugins and a simple API for creating new ones.

How to use the Editor after Installation.

  • Create new Blocks by pressing Enter or clicking the Plus Button
  • Press TAB or click on the Plus Button to view the Toolbox
  • Press TAB again to leaf Toolbox and select a Block you need. Then press Enter.

  • Select a text fragment and apply a style or insert a link from the Inline Toolbar

  • Use the «three-dots» button on the right to open Block Settings. From here, you can move and delete a Block or apply a Tool's settings, if it provided. For example, you can set a Heading level or List style.

Shortcuts

A few shortcuts are preset as available.

Shortcut Action Restrictions
TAB Show/leaf a Toolbox. On empty block
SHIFT+TAB Leaf back a Toolbox. While Toolbox is opened
ENTER Create a Block While Toolbox is opened and some Tool is selected
CMD+B Bold style On selection
CMD+I Italic style On selection
CMD+K Insert a link On selection

Each Tool can also have its own shortcuts. These are specified in the configuration of the Tool, for example:

var editor = new EditorJS({
  //...
  tools: {
    header: {
      class: Header,
      shortcut: 'CMD+SHIFT+H'
    },
    list: {
      class: List,
      shortcut: 'CMD+SHIFT+L'
    }
  }
  //...
 });

Installation Guide

There are few steps to run Editor.js on your site.

  1. Load Editor's core
  2. Load Tools
  3. Initialize Editor's instance

Step 1. Load Editor's core

Get Editor.js itself. It is a minified script with Editor's core and some default must-have tools.

Choose the most usable method of getting Editor for you.

  • Node package
  • Source from CDN
Option A. NPM install

Install the package via NPM or Yarn

npm i @editorjs/editorjs

Include module in your application

import EditorJS from '@editorjs/editorjs';
Option B. Use a CDN

You can load EditorJS directly from from jsDelivr CDN.

https://cdn.jsdelivr.net/npm/@editorjs/editorjs@latest

For example, place this in your HTML:

<script src="https://cdn.jsdelivr.net/npm/@editorjs/editorjs@latest"></script>

Or download the bundle file and use it from your server.

<script src="editor.js"></script>

Step 2. Load the Tools that you want to make available

Each Block is represented by a Tool. Tools are simple external scripts with their own logic. For example, there is a Header Tool into which you type your heading text. If you want to be able to use this, install the Header Tool the same way as the Editor (Node.js, CDN, local file).

Example: use Header from CDN

<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/bundle.js"></script>

Check Editor.js's community to see more ready-to-use Tools.

Step 3. Create Editor instance

Create an instance of Editor.js and pass Configuration Object with holderId and tools list.

<div id="editorjs"></div>

You can create a simple Editor with only default Paragraph Tool by passing a string with element's Id (wrapper for Editor) as a configuration param. Or use the default editorjs id for wrapper.

var editor = new EditorJS(); /** Zero-configuration */

// equals

var editor = new EditorJS('editorjs');

Or pass a whole settings object.

var editor = new EditorJS({
    /**
     * Create a holder for the Editor and pass its ID
     */
    holder : 'editorjs',

    /**
     * Available Tools list.
     * Pass Tool's class or Settings object for each Tool you want to use
     */
    tools: {
        header: {
          class: Header,
          inlineToolbar : true
        },
        // ...
    },

    /**
     * Previously saved data that should be rendered
     */
    data: {}
});

Saving Data

Call editor.save() and handle returned Promise with saved data.

editor.save()
  .then((savedData) => {
    console.log(savedData);
  });

Example

Take a look at the example.html to view more detailed examples.

Credits and references

About CodeX

CodeX is a team of digital specialists around the world interested in building high-quality open source products on a global market. We are open for young people who want to constantly improve their skills and grow professionally with experiments in cutting-edge technologies.

🌐 Join 👋 Twitter Instagram
codex.so codex.so/join @codex_team @codex_team
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].