UNPKG

re-quill

Version:
38 lines (29 loc) 752 B
# React Quill base on quill@1.3.7 inspired by https://github.com/zenoamaro/react-quill ## Example ```jsx import React from "react"; import ReactDOM from "react-dom"; import ReactQuill from "."; // ES6 function Example() { const [value, setValue] = React.useState("hello world"); const quill = React.useRef(); return ( <div> <ReactQuill ref={quill} placeholder="type something.." value={value} onChange={(html, _delta, _source) => setValue(html)} /> <div className="html"> <div dangerouslySetInnerHTML={{ __html: value }}></div> </div> </div> ); } ReactDOM.render(<Example />, document.getElementById("root")); ``` ## API Checkout <a href="https://github.com/zenoamaro/react-quill#api-reference">here</a>