Last active
November 9, 2020 17:30
-
-
Save edtsech/0189cecb493a82e02758b60ceea2dfca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react' | |
import * as ReactQuill from 'react-quill' | |
import { merge } from 'lodash' | |
import 'react-quill/dist/quill.snow.css' | |
const QUILL_MODULES = { | |
toolbar: [ | |
['bold', 'italic', 'underline'], | |
[{ list: 'ordered' }, { list: 'bullet' }], | |
['link'] | |
] | |
} | |
interface IAutoFocus { | |
autofocus?: boolean | |
} | |
class CustomQuill extends React.Component< | |
ReactQuill.ComponentProps & IAutoFocus | |
> { | |
quill = React.createRef<ReactQuill & ReactQuill.Mixin>() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
const quillEditorRef = useRef<ReactQuill>(null);