Open domchristie opened 7 years ago
I thought there was some case on older browsers not supporting 'input' that change would capture cases where keyup didn't (maybe right click -> paste for instance). However, at this point I think we can assume it's available: http://caniuse.com/#feat=input-event
Looks fine to me if you are OK with https://github.com/bgrins/ExpandingTextareas/pull/68#issuecomment-258918552
I thought there was some case on older browsers not supporting 'input' that change would capture cases where keyup didn't (maybe right click -> paste for instance)
Good point: I have added a paste
handler for browsers that do not support input
.
Removes the unnecessary call to update the clone textarea on
change
, since it should already have updated on theinput
event. It also exposes theupdate
method to the jQuery plugin, so that rather than accessing theExpanding
instance and callingupdate
:users can do:
as is shown in the updated demo.