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

Added a change event to the editor #50

Open
wants to merge 1 commit into
from

Conversation

Projects
None yet
5 participants
@jordandh
Contributor

jordandh commented Apr 19, 2013

Based on what we talked about I went ahead and added the change event to the editor.

@gojko

This comment has been minimized.

Show comment
Hide comment
@gojko

gojko Apr 19, 2013

Contributor

I was looking into this as well. I think this needs a bit more love :) I'm travelling today so I won't be able to complete it, but I was thinking about caching the old version and actually comparing it with the current one before triggering change. this should prevent multiple fake triggers and preventing events that don't change content

Contributor

gojko commented Apr 19, 2013

I was looking into this as well. I think this needs a bit more love :) I'm travelling today so I won't be able to complete it, but I was thinking about caching the old version and actually comparing it with the current one before triggering change. this should prevent multiple fake triggers and preventing events that don't change content

@jordandh

This comment has been minimized.

Show comment
Hide comment
@jordandh

jordandh Apr 19, 2013

Contributor

I understand the need to make it as accurate as possible. I am worried about holding onto the old value though. If there are a couple of images in the editor then it could be multiple MBs being stored and compared. That could be slow and consume a decent chunk of memory.

Contributor

jordandh commented Apr 19, 2013

I understand the need to make it as accurate as possible. I am worried about holding onto the old value though. If there are a couple of images in the editor then it could be multiple MBs being stored and compared. That could be slow and consume a decent chunk of memory.

@gojko

This comment has been minimized.

Show comment
Hide comment
@gojko

gojko Apr 20, 2013

Contributor

hm... you're right. perhaps a checksum then

Contributor

gojko commented Apr 20, 2013

hm... you're right. perhaps a checksum then

@SET001

This comment has been minimized.

Show comment
Hide comment
@SET001

SET001 May 7, 2013

How to use this to catch changes?
For now i use this

MutationObserver = window.MutationObserver || window.WebKitMutationObserver
observer = new MutationObserver (mutations, observer) ->
    scope.data = editor.html()
observer.observe document,
    subtree: true
    attributes: true

SET001 commented May 7, 2013

How to use this to catch changes?
For now i use this

MutationObserver = window.MutationObserver || window.WebKitMutationObserver
observer = new MutationObserver (mutations, observer) ->
    scope.data = editor.html()
observer.observe document,
    subtree: true
    attributes: true
@festaans

This comment has been minimized.

Show comment
Hide comment
@festaans

festaans May 18, 2013

Hi, I'm trying to use bootstrap wysiwyg as a "local" offline editor. I'm currently trying to make use of garlic.js to get the info in the editor persistent but no luck yet. Any ideas?

Hi, I'm trying to use bootstrap wysiwyg as a "local" offline editor. I'm currently trying to make use of garlic.js to get the info in the editor persistent but no luck yet. Any ideas?

@mm01

This comment has been minimized.

Show comment
Hide comment
@mm01

mm01 Jan 6, 2014

how can i bind and use chane event?

mm01 commented Jan 6, 2014

how can i bind and use chane event?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment