Skip to content
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

Deprecate jQuery.nodeName, remove in 4.0 #3475

Closed
mgol opened this issue Dec 27, 2016 · 9 comments
Closed

Deprecate jQuery.nodeName, remove in 4.0 #3475

mgol opened this issue Dec 27, 2016 · 9 comments

Comments

@mgol
Copy link
Member

mgol commented Dec 27, 2016

Description

jQuery.nodeName is another undocumented utility function that's exposed on the jQuery object. We should remove it (probably in 4.0 as it's been there for a long time).

Link to test case

https://jsfiddle.net/o648k3ga/1/

@timmywil
Copy link
Member

If we want to remove it in 4.0, we should deprecate in 3.2.

@mgol
Copy link
Member Author

mgol commented Dec 27, 2016

We can't deprecate something that's not documented. :) It's more than deprecated.

@timmywil
Copy link
Member

timmywil commented Dec 27, 2016

@mgol I'd still like to give notice. We're doing the same for other undocumented functions that we plan on removing. While not required, you might call it courteous.

@timmywil timmywil modified the milestones: 3.2.0, 4.0.0 Jan 9, 2017
@timmywil timmywil changed the title Hide jQuery.nodeName Deprecate jQuery.nodeName, remove in 4.0 Jan 9, 2017
@karan-96
Copy link
Contributor

Hello . i think ,to fix up this issue, jquery.nodeName function should be removed from src/core.js and added to src/deprecated.js. Correct me if i am wrong or if i am missing something.Can i take up this issue and work with this approach?

@timmywil
Copy link
Member

@karan-96 That would be great! You'll find information on how to contribute here, with info on commits and PRs here. As far as the required work for this issue, that should be all the work needed for jQuery core. We'll also want to add a warning to the jQuery migrate plugin.

karan-96 added a commit to karan-96/jquery that referenced this issue Jan 17, 2017
karan-96 added a commit to karan-96/jquery that referenced this issue Jan 17, 2017
@dmethvin
Copy link
Member

Just to clarify what has to be done here, I know it's got a PR at gh-3505 but we have to eliminate internal calls in order to warn about it in jQuery Migrate.

  • Create an internal nodeName and put it in src/var/nodeName.js
  • Change all internal calls to jQuery.nodeName to our new nodeName function
  • Expose the internal nodeName as jQuery.nodeName in deprecated.js

Does that sound right to everyone?

@mgol
Copy link
Member Author

mgol commented Jan 23, 2017

@dmethvin yes, that's exactly what I said in #3505 (comment) a few days ago. :)

@mgol
Copy link
Member Author

mgol commented Jan 23, 2017

(although it seems it doesn't have to be a var-module in case of an exported function)

@dmethvin
Copy link
Member

@mgol oh sorry, I missed that!

karan-96 added a commit to karan-96/jquery that referenced this issue Jan 27, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Jan 27, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Jan 27, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Jan 28, 2017
@mgol mgol self-assigned this Feb 13, 2017
karan-96 added a commit to karan-96/jquery that referenced this issue Feb 16, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Feb 16, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Feb 16, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Feb 16, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Feb 16, 2017
karan-96 pushed a commit to karan-96/jquery that referenced this issue Feb 21, 2017
@mgol mgol closed this as completed in ac9e301 Mar 1, 2017
wmfphab pushed a commit to wikimedia/mediawiki that referenced this issue Mar 18, 2017
jQuery.nodeName gets deprecated in jQuery 3.2.0. [1] [2]

[1] https://blog.jquery.com/2017/03/16/jquery-3-2-0-is-out/
[2] jquery/jquery#3475

Change-Id: I7e6d5191e4db5117dbcfa89b07f25e672ed1e4d2
@lock lock bot locked as resolved and limited conversation to collaborators Jun 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

4 participants