How to update react-meteor-data to latest version?

I’m just wandering what one needs to do in order to use the latest version of react-meteor-data and for a package that’s mentioned in Meteor official docs, this is weirdly complicated.

When I run meteor update, this is the output:

The following top-level dependencies were not updated to the very latest version available:
latest version available:
 * alanning:roles 1.2.19 (3.2.3 is available) 
 * react-meteor-data 0.2.16 (2.1.1 is available)

When I run meteor update react-meteor-data, the output is:
The specified packages are at their latest compatible versions.

Why would the package be incompatible? How do I find out?
I don’t install many packages in general, so I find it a bit odd.

This link explains that it’s possible to update the package using the following command:
meteor update react-meteor-data --allow-incompatible-update

You can understand why I prefer to find a cleaner solution.

Seems like I’m not the only one facing this but I couldn’t find a clear explanation on what the hack is going on with that package.
The first github link if you google “meteor-react-data github” seems to be dead (the other links are for forks).
I finally was able to find the official repository here and according to their README.md my project is compatible with latest version.

Any advice? Do I have to use the --allow-incompatible-update flag?
Thanks in advance :pray:

P.S. I’m using Meteor v1.10.2.

I’m not sure if this would work, but you can try using the ! flag to force install the package

You can try editing your .meteor/packages file replace react-meteor-data with react-meteor-data@2.1.1!
As for alanning:roles I recommend you read migration guide from v1 to v3 before you upgrade your package

1 Like

If I remember correctly, the reason why it is not compatible is due to the supported version of React in the latest Meteor. Meteor supports the earlier version of react that is not compatible with the new version of meteor-react-data

If you have the required react version, then go ahead and install the ‘incompatible’ version

1 Like

That makes sense. thanks @rjdavid!
I installed latest version using --allow-incompatible-update and seems like everything works as expected :v:.

Another small question - do you know what react versions are supported by Meteor? I see that in my package.json I have react v16.8.6 which is from over a year ago, with react latest version being v16.13.1.

Should I just update react package myself or are there other recommendations regarding updating react?
I didn’t find any mentioning of that in Meteor releases information.
Thanks guys.

I forgot the minimum version supported. You should update react separately from Meteor e.g. through npm. We are also running 16.13.1

1 Like

I’ve run into the odd situation where it would seemingly get “stuck” on a previous version, even if there wasn’t a compatibility issue (ie. Meteor up to date, other packages all up to date).

The easiest workaround around would be to remove the package (meteor remove the-package) and add it again (meteor add the-package). The feels safer to me than the --allow-incompatible-update just because you know that there is no compatibility issue.

1 Like