I'm requesting a consistent initialization event when the editor is created for a module I'm working on.
If Quill is init'd on a DOMElement that has existing innerHTML, then a editor-change or text-change event is fired. However, if there is no existing HTML, then an event is not fired.
I could create HTML within the DOM during module initialization (which occurs during theme.init(), but a local let html = ... variable within Quill creates ambiguity/inconsistency. So, I have the user trigger a module-specific .init() function after the editor has been initialized.
On Quill 1.X latest, this doesn't appear to be an issue.
Quill 2.0 has been released (announcement post) with many changes and fixes. If this is still an issue please create a new issue after reviewing our updated Contributing guide :pray:
I'm requesting a consistent initialization event when the editor is created for a module I'm working on.
If Quill is init'd on a DOMElement that has existing innerHTML, then a
editor-change
ortext-change
event is fired. However, if there is no existing HTML, then an event is not fired.I could create HTML within the DOM during module initialization (which occurs during
theme.init()
, but a locallet html = ...
variable within Quill creates ambiguity/inconsistency. So, I have the user trigger a module-specific.init()
function after the editor has been initialized.On Quill 1.X latest, this doesn't appear to be an issue.
Steps for Reproduction
called on quill2
Expected behavior: Regardless of DOM content on init, trigger a
text-change
event or a similar event.Actual behavior: Only
text-change
triggered when DOM content exists.Platforms: Windows Firefox, Chrome, ... Version: 2.0 (Latest per NPM)