Is there any way to determine if the content has changed or callback on modification? I could possibly use the keyUp callback to detect modifications from keys but this would not be able to detect modifications from mouse-actions. Is there a way to do this or perhaps in the future?
Usage case: I want to detect change and update the icon color for the save button to indicate things have changed. I currently use Redactor as my text editor which does this but I want to switch to summernote.
Actually I'd find this handy for client's too, so on changes, the save button that I've added to the toolbar could change colour to indicate they need to save.
onChange: function ($editable, sHtml) {
console.log($editable, sHtml);
}
http://sandbox.thewikies.com/html5-experiments/key-events.html
onChange does not seem to fire when buttons are selected such as center align or changing a font. Any idea how to capture these events?
Most helpful comment
onChange does not seem to fire when buttons are selected such as center align or changing a font. Any idea how to capture these events?