capacitor-community / fcm

Enable Firebase Cloud Messaging for Capacitor apps
https://capacitor.ionicframework.com/docs/
MIT License
238 stars 83 forks source link

example app can't be built #131

Open jcesarmobile opened 1 year ago

jcesarmobile commented 1 year ago

The example app has a mix of angular 7 and angular 12 dependencies which conflict with each other. Also uses @ionic/angular 4.x, which is not compatible with angular 12

It's not possible to install on npm 7+ because of peer dependencies. If you install with npm install --force or use npm 6, it installs, but then npm run build fails with multiple errors.

ap1969 commented 1 year ago

Confirmed, same problem:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: capacitor-fcm-demo@0.0.1
npm ERR! Found: @angular/core@12.2.17
npm ERR! node_modules/@angular/core
npm ERR!   @angular/core@"^12.0.4" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/core@"7.2.16" from @angular/http@7.2.16
npm ERR! node_modules/@angular/http
npm ERR!   @angular/http@"^7.2.2" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.