I just started using react-quill in one of my project it shows me this error and the page crashes.
Error:
quill.js:148 Uncaught Error: [Parchment] Unable to create [object HTMLDivElement] blot
at new ParchmentError (quill.js:148)
at Object.create (quill.js:178)
at new Quill (quill.js:1153)
at Object.createEditor (mixin.js:12)
at Object.componentDidMount (component.js:202)
at Object.chainedFunction [as componentDidMount] (factory.js:741)
at commitLifeCycles (react-dom.development.js:19814)
at commitLayoutEffects (react-dom.development.js:22803)
at HTMLUnknownElement.callCallback (react-dom.development.js:188)
at Object.invokeGuardedCallbackDev (react-dom.development.js:237)
at invokeGuardedCallback (react-dom.development.js:292)
at commitRootImpl (react-dom.development.js:22541)
at unstable_runWithPriority (scheduler.development.js:653)
at runWithPriority$1 (react-dom.development.js:11039)
at commitRoot (react-dom.development.js:22381)
at finishSyncRender (react-dom.development.js:21807)
at performSyncWorkOnRoot (react-dom.development.js:21793)
at react-dom.development.js:11089
at unstable_runWithPriority (scheduler.development.js:653)
at runWithPriority$1 (react-dom.development.js:11039)
at flushSyncCallbackQueueImpl (react-dom.development.js:11084)
at flushSyncCallbackQueue (react-dom.development.js:11072)
at discreteUpdates$1 (react-dom.development.js:21893)
at discreteUpdates (react-dom.development.js:806)
at dispatchDiscreteEvent (react-dom.development.j
I am using just a simple code right now
import React, { Component } from "react";
import ReactQuill from 'react-quill';
import 'react-quill/dist/quill.snow.css';
class Text extends Component {
state = {
text: '',
};
handleChange = (value) => {
this.setState({ text: value });
};
render() {
return <ReactQuill value={this.state.text} onChange={this.handleChange} />;
}
}
export default Text;
I have searched all the issues related to this but couldn't find any solution for it.
Note: I tried to use this in my other project It was working perfectly fine in it.
I appreciate your help so much. Thanks in advance.