-
Notifications
You must be signed in to change notification settings - Fork 550
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
onChange event doesn't work in IE11 #84
Comments
The question is "what works with IE"... |
Looks to work fine for me, the arrow function in the example will not work as IE does not support them. But changing the code to a standard function expression works fine.
|
Fair points above. I think it would be wise to put the more compatible version in the demo code. Although I figured it out myself and learnt something. In any case, I successfully implemented use of the editor in my application. Thanks. |
Actually looking into this further as I just noticed an issue with IE11 on my implementation. It is actually an issue even once you change to the function expression as the onChange event is never triggered. This is because IE does not support input change on contenteditable items. I have made a simple code change to detect IE and change the event listener based on this. I doubt @jaredreich would want this added IE fix in the master branch so have added the code below for anyone else who needs IE11 support. You need to replace the code which watches for content changes:
with:
|
I think my way around it was was not using the onChange feature in fact hence above answer may have been helpful. |
Even when using the 'textinput' event that will not solve all issues as any changes triggered from the editor buttons will not trigger a change. I have needed to add a fair amount of custom code to get the change event working. |
I think I see this as a plugin opportunity rather than a bug. The whole point of pell is to remain insanely small by forgetting about stupid browser differences that will go away in the future anyways. However, IE is of still used quite a lot in the wild... so I do think it's worth my time to make an IE plugin. |
Is there any update on this? The onChange event isn't working in IE for me, even with the standard function expression syntax. Thanks! |
@mikezukerman The issue is still open, so no update from me yet. This will probably be part of a future 2.0 release that allows plugins. Or maybe IE usage will be down to 0% by that time? Haha. |
For now I used MutationObservers specially for IE11 checking for Trident in UA and well it sure is not the most beautiful but at least it works, so to pell-content node I attach something like this:
|
Could you check this solution, @jaredreich ? Similar to @matChojecky comment. I saw it when the pr was created |
@jaredreich I suggest removing the IE 9+ support from the README since it's not supported at the moment and it's not planned on being fixed (at least without a plugin or v2.0) |
The onChange setting works in Chrome but doesn't work in IE 11.
The text was updated successfully, but these errors were encountered: