@techstack/lexical
v2.2.40
Published
a wrapper for facebook/lexical for react
Downloads
2,247
Readme
lexical
This is a wrapper around the meta lexical library. below is how you install and use it. PRs are welcome.
npm i -S @techstack/lexical
There are two ways to use it the all included solution or the composable way.
All included
import Editor from "@techstack/lexical";
import "@techstack/lexical/css";
<Editor name="editor" onChange={fn} placeholder="" value="" />
Composable way (below is list of included plugins and components)
import Editor from "@techstack/lexical/editor";
import {
pluginName
} from "@techstack/lexical/plugins";
import { Toolbar } from "@techstack/lexical/components";
import "@techstack/lexical/css";
<Editor name="" onChange={} placeholder="" value="">
<Toolbar>
{toolbarplugins}
</Toolbar>
{non toolbar plugins}
</Editor>
Plugins
list coming soonish
Components
- Toolbar
- Divider