-
-
Notifications
You must be signed in to change notification settings - Fork 316
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change event #90
Comments
Hi @redone80 , Due to the nature of WYSIWIG implementations you are not dealing with form fields which natively have an onChange event that can be used to monitor for change. This is a content editable page division therefore the keyUp event (fired after content is updated) is currently the best way to watch for change. You would need to do something like fire the .getContents() function on the editor after each keyUp and compare it to the last saved contents to determine if change has occured - if you detect change then trigger the save event or any other event you want. JiHong88 may have other advice to give. DG |
Hi @redone80 , @DeZZar is right. Due to the nature of the "contenteditable" implementation, the "onchange" event does not occur. Instead, will be able to implement the "onChange" event by detecting the history stack changes in the editor. I will include it in the version to be updated today. Thank you. |
Hi JiHong88,
Can you add onchange event for auto update content?
onKeyUp event only track when I type. But I click toolbar button it can not track.
The text was updated successfully, but these errors were encountered: