TAPevents / tap-i18n

A comprehensive internationalization solution for Meteor.
MIT License
329 stars 86 forks source link

Compatibility with JQuery 3.0 #218

Closed fameteor closed 4 years ago

fameteor commented 4 years ago

I would to use your very nice TAPi18n Meteor package with Meteor 1.9 and Bootstrap 4 installed. When I try to install TAPi18n in this context, I get an incompatibility message for Jquery 3.x.x and I must user the meteor add tap:i18n --allow-incompatible-update command to be able to install it and thus I get Jquery V1.x.x.

Is there a way to install TAPi18n without downgrading Jquery ?

Thanks a lot

evolross commented 4 years ago

Yes, you can meteor add jquery@3.0.0!. This will add the updated Meteor jquery package that is set to simply reference whichever version you have installed via npm (e.g. meteor npm install --save jquery@X.X.X). The ! modifier on the package tells Meteor to weaken any dependencies from other Meteor packages on that package. So any packages that have older versions of Meteor jquery pinned (and there are many) will use the updated Meteor 3.0.0 version which simply pulls in the installed NPM version. Prior to 3.0.0 it was the actual jQuery package wrapped for Meteor (like many other packages - underscore, etc.)

In my app, so far, it seems like tap:i18n is perfectly compatible with jQuery 3. Though I did have to use a fork in order to remove the old Meteor version of aldeed:simple-schema for the new NPM simpl-schema. But that's a different topic.

More info on about the Meteor jquery@3.0.0 and ! modifier in the forum topic Replace Meteor base Jquery for the NPM one.

fameteor commented 4 years ago

Great, thanks a lot for you very detailled answer !