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

Updating jQuery Dependency to 3.x Should Cause Major Version Update #10295

Closed
someyoungideas opened this issue Jun 29, 2017 · 5 comments
Closed

Comments

@someyoungideas
Copy link

In the recent v6.4.0 release all dependencies to jQuery were bumped from >=2.2.0 to >=3.0.0. Seeing that this is a MAJOR version release in a dependency I was wondering why Foundation's release was not considered a MAJOR version release?

This change in Foundation caused some breaking changes in our site once the jQuery version updated with this release. This is more looking for thoughts why or why not Foundation's version was changed to match the MAJOR version change in jQuery.

@IamManchanda
Copy link
Contributor

cc @kball

@QWp6t
Copy link

QWp6t commented Jul 3, 2017

Does Foundation use any of jQuery 3's API that isn't available in 1 or 2? If not, then it's API-compatible and therefore doesn't require a major version update, but Zurb should consider changing dependency to >= 1.12 or something similar.

Bootstrap went through a similar issue here: twbs/bootstrap#17494

In that PR, they raised dependency to 2.x. WordPress developers pointed out that WordPress ships with jQuery 1.x still, and the move by Bootstrap would alienate those developers. (Love it or hate it, WordPress is huge in our industry, and thus winds up shaping the way things progress.) Since Bootstrap doesn't actually use any jQuery APIs that are specific to version 2, then there's no reason for that version to be a hard dependency.

Bootstrap ultimately reversed their move here: twbs/bootstrap#18267

If Foundation does in fact make use of APIs that aren't available 1.x, then yeah, that should warrant a major version update.

@kball
Copy link
Contributor

kball commented Jul 3, 2017

This is a good point... we do in fact work with older versions of jquery (there are plenty of folks using foundation with Wordpress)... however we strongly encourage later versions. Perhaps the right solution would be to reduce the minimum value in the framework while having the templates consistently push for latest and greatest? I'm by no means a dependency expert - would love other voices here @zurb/yetinauts

With regards to the major/minor question, we've explicitly avoided semver as it seems to create far more confusion for humans than it solves for machines.

@DanielRuf
Copy link
Contributor

Imo we should stop using jQuery in v7.

The change is ok and you can still install and pin jQuery 2.

@colin-marshall
Copy link
Contributor

@someyoungideas, as @DanielRuf mentioned, you should be able to pin jQuery to v2 in package.json and still use it with Foundation with no problems. This should alleviate your breaking changes, but I'm guessing you already took care of that seeing as how this is 9 months later. I'm closing this out, but feel free to reopen if you feel I have done so in error. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants