Skip to content

bind/unbind is deprecreated #241

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

Closed
darcyparker opened this issue May 12, 2020 · 2 comments
Closed

bind/unbind is deprecreated #241

darcyparker opened this issue May 12, 2020 · 2 comments

Comments

@darcyparker
Copy link
Contributor

This is not a serious error... but it bind and unbind are deprecated.

You won't have a problem if using jqlite, because in AngularJS, JQLite.prototype.bind = JQLite.prototype.on; and JQLite.prototype.unbind = JQLite.prototype.off;

But if you load JQuery 3.51 and the unminified jquery-migrate.js you will get logs about usage of deprecated functionality.

The above cases of bind() and unbind() should be on() and off() respectively.

darcyparker added a commit to darcyparker/ui-scroll that referenced this issue May 12, 2020
* Replace deprecrated .bind() and .unbind() with .on() and .off() respectively.
* angular-ui#241
* https://api.jquery.com/category/deprecated/deprecated-3.0/
@dhilt
Copy link
Member

dhilt commented May 13, 2020

I made little research. The on/off methods appeared in jQuery 1.7 in 2011 and in AngularJS 1.2 in 2013. The angular-ui-scroll does not support AngularJS less than 1.2. So the change you proposed seems reasonable and will not affect any of the lib users. I switched base branch of your PR as I'm going to make some additional work. Thanks for your contribution!

@dhilt
Copy link
Member

dhilt commented May 13, 2020

Closing, as angular-ui-scroll v1.8.1 had been released.

@dhilt dhilt closed this as completed May 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants