@remirror/dom
Use remirror directly in the dom.
Why
You've heard great things about prosemirror and would like to use it in your app, but you're slightly intimidated by some of the moving parts. You don't really want to deal with Schema, Nodes, Marks, Plugins, Decorations. You just want an editor.
This library provides an abstraction that might be right for you.
The functionality of the prosemirror library is wrapped up into extensions which manage the work for you.
Installation
yarn add @remirror/dom
pnpm add @remirror/dom
npm install @remirror/dom
Usage
The following code is a guide to get you started.
import { createDomEditor, createDomManager } from 'remirror/dom';
import { BoldExtension } from 'remirror/extensions';
const element = document.querySelector('#editor');
const manager = createDomManager([new BoldExtension()]);
const editor = createDomEditor({ manager, element });
editor.addHandler('change', () => log('your editor has changed'));
editor.commands.toggleBold();