Closed naitikpatel1990 closed 4 years ago
@andrehtissot @andretissot I am also facing the same issue as the android build is fine but for ios, I am unable to add the platform as it stuck on pod install and command: pod --version. I have to deliver my project today and due to a name and bundle id change I have to re-add the platform and rebuild but it got stuck on platform install
For permission on ios, make sure you call method fcmrequestpushpermission: https://github.com/andrehtissot/cordova-plugin-fcm-with-dependecy-updated#fcmrequestpushpermission
Yes @DaedalusAB
But plugin is not able to install for iOS so that method for permission won't able to call.
Do you import FCM from @ionic-native/fcm or from 'cordova-plugin-fcm-with-dependancy-updated/...'
Make sure you use the latter and make sure you init the plugin after platform is ready.
Check here:
Plugin is not installing at all.
Though I do have npm package install as you can check in my above package.json
@DaedalusAB when we add a platform for ios it stuck on pod install command: pod -version abd I am unable to move forward
@anshsoni143 maybe this helps: https://github.com/andrehtissot/cordova-plugin-fcm-with-dependecy-updated/issues/150
@DaedalusAB
i am able to install plugin. But i do have one issue remain.
There is no notification section in Settings --> App ( as above question screenshot )
FYI i do add PushNotification in capabilities, following is screenshot of it.
Please guide me what i did wrong ?
@naitikpatel1990 how you added the plugin can you guid me
@anshsoni143
I did download zip of this plugin.
make folder called "custom_plugins" in my ionic project root directory. ( you can make anywhere but i prefer to set inside project only to get relative path when install )
then unzip your plugin in "custom_plugins" folder.
so now your plugin code will be like in ionicProject --> custom_plugins --> cordova-plugin-fcm-with-dependecy-updated-master
Now open plugin.xml from ionicProject --> custom_plugins --> cordova-plugin-fcm-with-dependecy-updated-master --> plugin.xml
do following changes in it:
<!-- FIREBASE COCOAPODS-->
<!-- <podspec>
<config>
<source url="https://github.com/CocoaPods/Specs.git"/>
</config>
<pods>
<pod name="Firebase/Analytics" spec=">= 6.21.0" />
<pod name="Firebase/Messaging" spec=">= 6.21.0" />
</pods>
</podspec> -->
<framework src="Firebase/Core" type="podspec" spec=">= 6.21.0"/>
<framework src="Firebase/Analytics" type="podspec" spec=">= 6.21.0"/>
<framework src="Firebase/Messaging" type="podspec" spec=">= 6.21.0"/>
SO above you need to commented some code and add 3 lines given in above code snippet:
Now add you plugin with following command:
ionic cordova plugin add custom_plugins/cordova-plugin-fcm-with-dependecy-updated-master
and it should able to install plugin.
@naitikpatel1990 what is your iOS version as i am using ios@latest
I am using ios 6.1.0
Which is latest i guess.
@naitikpatel1990 Make sure you call method requestPushPermission(), and make sure you call it after platform.ready()
Here is an example:
@DaedalusAB
Thank you. It's working great now.
@naitikpatel1990 and @DaedalusAB Thanks for the help. Finally able to build and push app.
Describe the bug I am using two firebase plugin in my app. Firebase-authentication and this one. Both have different cocopods URL.
SO first i got dual dependency error. Then i did manually download plugin change cocopods URL to CDN one and able to install it using my local plugin folder path.
Let me know if i did wrong. in above because that be affect my following issue.
I am not able to call fcm notification permission one.
Also weird is even in IOS device -->Settings--> My App, i can't find Notification section. Please check below screenshot
Environment (please complete the following information):
Following is package.json:
FYI: No issues with android. Android works completely fine