jquery-patch.js: Misleading label and description ("Support version 1.8.x and newer of jQuery core")
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 11.3k
- Forks
- 5.2k
- PR merge metrics
- No merged PRs in 30d
Description
The jquery-patch.js component increases backwards compatibility by allowing current jQuery UI versions to be used with jQuery core versions anterior to 3.5 (until 1.8). jQuery core 3.5+ would otherwise be required, as explained in the Newer Core features section of the jQuery UI 1.13 Upgrade Guide:
As part of making sure jQuery UI doesn't depend on deprecated Core APIs, we started using some newer Core APIs, polyfilling them in the jquery-patch.js file for older jQuery versions. If you haven't included jquery-1-7.js in your bundle of jQuery UI 1.12.x, you may still need to include jquery-patch.js when migrating to UI 1.13.x; it's required for all jQuery versions older than 3.5.0.
Unfortunately, that is pretty far from what one understands when using the Download Builder, which calls it "jQuery 1.8+ Support" and describes its role as "Support version 1.8.x and newer of jQuery core".
This name and this description come from the label and description defined in the file's header. Even though the previous versions were poor/outdated, they became misleading and fragile when support for core 1.7 was dropped.
The new texts make it backwards, implying that jquery-patch provides compatibility with new versions, rather than with old versions. Moreover, it makes the information time-sensitive, as while they may not be quite wrong at this time, there is no guarantee that jQuery UI 1.13 will be compatible with jQuery core 4.
I suggest the following:
//>>label: Legacy jQuery core compatibility
//>>description: Support versions of jQuery core lower than 3.5 (down to 1.8)
By the way, this file's role would be much clearer if it was named "legacy-jquery-core.js".
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open ui/jquery-patch.js and inspect its header label and description, then check how the Download Builder presents them. Update the two header texts to describe compatibility with jQuery core versions below 3.5 down to 1.8; renaming the file is suggested separately.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, jquery
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100