You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However I'm working on a capacitor project and although it was fairly painless to install the plugin, I'm now having issues building the app due to version mismatches:
Error: All gms/firebase libraries must use the exact same version specification (mixing versions can lead to runtime crashes). Found versions 17.0.0, 11.0.1. Examples include com.google.android.gms:play-services-base:17.0.0 and com.google.android.gms:play-services-analytics-impl:11.0.1
It appears this problem could be trivially fixed by specifying the GMS_VERSION, but I don't know if that's possible with capacitor. Any help would be greatly appreciated. :)
The text was updated successfully, but these errors were encountered:
Create scripts/setGoogleAnalyticsVersion.ts and add the following contents:
import*asfsfrom'fs';constGMS_VERSION='17.0.0';constPLUGIN_PATH='./node_modules/cordova-plugin-google-analytics/plugin.xml';console.log(`Attempting to set $GMS_VERSION = ${GMS_VERSION} in ${PLUGIN_PATH}`);constpluginContents=fs.readFileSync(PLUGIN_PATH).toString('utf8');constpluginContentsUpdated=pluginContents.replace('$GMS_VERSION',GMS_VERSION);fs.writeFileSync(PLUGIN_PATH,pluginContentsUpdated);console.log('Success!');
No doubt there are better ways to achieve the same thing, but at least it works.
In the documentation it says:
Use the GMS_VERSION to align the required play-services version with other plugins.
However I'm working on a capacitor project and although it was fairly painless to install the plugin, I'm now having issues building the app due to version mismatches:
It appears this problem could be trivially fixed by specifying the
GMS_VERSION
, but I don't know if that's possible with capacitor. Any help would be greatly appreciated. :)The text was updated successfully, but these errors were encountered: