Комментарии:
This is outdated. I commented with the updated version but my comment was deleted for some reason. Also, Simon forgot to show one last part in xcode which was how to add push notifications via Sign & Capabilities. If you do not do this, notifications won't work in iOS.
ОтветитьIs this still working?
Thanks in advance guys!
Hi Simon!
Thanks for the tutorial!
Quick question: is it possible to use a custom sound for @capacitor/push-notifications?
TQ for your tutorial. i would like to know is it possible to open app when receive the notification from firebase? in android or ios TQVM
ОтветитьHi Simon. Great Tutorial but i'm battling since fews days now. I receive notifications when the app is closed, in background or in forground. Works great. But when the app is open and i tap on it the pushNotificationReceived event is not triggered as compared to when it is closed. How can i solve this issue please?
ОтветитьDo you have something for the latest onesignal plugin version? I mean the Beta 5.0.0. I just updated my project to that plugin version but mehotds seem to be quite different.
ОтветитьThat was a great tutorial. But seems like `pushNotificationActionPerformed` no longer is triggered for android emulator. I can't get it to work and seems like people have had issues with this. I am using this with Angular 16 and Standalone components. Have tried debugging it in multiple ways, but can't seem to find a solution.
ОтветитьHi Simon! is it true that push notification for IOS do not need the developers program anymore?
ОтветитьGreat video, thanks for sharing!
Ответитьhow do i send a push notification to a user from the application itself. Like for exemple when a user buys a product and i want the seller to get a notification that his product has been sold?
Ответитьcan make new push notification using capacitor using android
ОтветитьHi Simon, thank you for the tutorial!
If have an issue with the router push to the detail page: when the app is closed in the background and gets opened with a push by id, the router push is not working and only the app (startpage) opens.
github links?
ОтветитьHi , i'm using "@capacitor/push-notifications": "^4.1.2" for implement push notification in android app but facing issue like if app open that time i can't able to get any event on tap of that notification can you help me how i can retrieve click tapping event when app is open. Currently i'm using below eventlistner for notification.
// Method called when tapping on a notification
await PushNotifications.addListener('pushNotificationActionPerformed',
async (notification: ActionPerformed) => {
console.log('Push action performed- ', notification);
}
);
Thank you, Simon. You help a lot!
ОтветитьThanks!
Ответитьall videos is a good, thanks sir.
Ответитьerror: cannot access Service
public class MessagingService extends FirebaseMessagingService {
^
class file for android.app.Service not found
Thanks Simon, these tutorials and Angular tutorials with Ionic in particular are really helpful considering just how many things can go wrong when you're battling through the code alone! Glad to see things are slowly getting easier with the Ionic workflow
Ответитьhey simon i followed your video step by step but i got an error
node_modules/@capacitor/push-notifications/ios/Plugin/PushNotificationsHandler.swift:32:44: error build: Value of type 'CAPPlugin' has no member 'getConfig'
i am using xcode 14 and ionic 6.20.1 and node 16.17.0
can you please help .
Thanks
Thank you Simon. You are the best. ActionPerformed event doesn't fire if the app was killed, so when user tap on notification iOS just open my app and I unable to retrieve additional payload data (detailId) for open proper detail page. How can I mange this issue?
ОтветитьThank you for great guide! Also thanks for the hint with the router.
ОтветитьWell nobody replied to my question a year ago and now I have encountered another issue after nearly two years of using Ioninc Push Notificaitons. The Token is now expired and there are no methods within the Ionic docs to perform a token refresh.
ОтветитьAlso make a Video on Push notification Icons.
ОтветитьGreat tutorial Simon, thanks for this guide.
I have been able to make iOS push notifications works !
Sadly, it's not working on android :/, registration doesn't work (got a MISSING_INSTANCEID_SERVICE error)
EDIT : problem solved, it was because my phone didn't have play store (Huawei and all their new smartphones don't have Google Play Services)
There is still a part in the documentation I don't understand. It's evoking $firebaseMessagingVersion variable in variables.gradle file. I was wondering if it was up to us to add this variable ourselves in the file or capacitor is supposed to generate it automatically ? Personnaly I don't have it by default.
If anyone is around and has the answer to my question, I would be grateful.
Capicator push notification's notificationReceived listener didn't get fired when app is kill or in background
I need that to show the total Badge count and count of different type of notification like chat notification count or product post count,
One possible workaround is to implement getDeliveredNotification and get the notification count to show inside different part of app.
That word fine with on iOS
But On android getDeliveredNotification don't give additional data so not able to count different type of notification.
I'm wondering how you show badge count when app is in background.
Can you please help
Or any other who know how to achieve this.
send great notifications
ОтветитьGreat tutor. Enjoying of your videos. But having issue on attaching image to push on IOS. Any information on that?
ОтветитьI am getting "remote notifications are not supported in the simulator". Do you know how to solve it? I am using XCode v13.3. Thanks!
Ответитьbuen video, tuve un problema no se si a alguien más le sucede, me llega la notificación pero no se despliega la alerta emergente.... solo queda en la sección de notificaciones cuando aparece. ¿Alguien sabe porque?
ОтветитьGreat tutorial. I would like to ask what is the correct way to handle token refresh. The token gets outdated in time right ? Is is correct way to register for push notification every time user logs in and then compare the token with the one stored in database and update it if it differs ?
ОтветитьHuge thanks for your tutorial, iOS part is not intuitive at all but you made it as simple as it could be. 👍
Ответитьso you meant to say that in order to display push notification in android and ios, I have to download and install a file to my capacitor app? so whats the difference of switching cordova to capacitor if its still the same?
ОтветитьAmazing Guide!! thank you sooo much <3333
ОтветитьHello, @Simon Grimm! Could you please share with us if there is a way to make the push notifications work if the device is locked and the phone sleeps (the screen is black)?
ОтветитьHi Simon. I'm getting this error message can you help me with it [Firebase/Messaging][I-FCM012002] Error in application:didFailToRegisterForRemoteNotificationsWithError: remote notifications are not supported in the simulator
Ответитьdoes anyone know of a tutorial that uses capacitor push notifications and azure notification hubs? not sure why it's so hard to find
ОтветитьHi, and thank you for the tutorial!
Sometimes the "pushNotificationActionPerformed" listener is not triggered. When the app is closed, after we get a notification, the app is open and the listener is working fine. When the application is in the background and we open a notification, the listener is not triggered. In most cases it works even when the application is in the background. But sometimes it's not triggered, and we don't know what can be the problem
. Do you have any idea or suggestion why sometimes the listener it’s not triggered? Any help would be great. The problem occured when app rest in background for longer time (a day for example). Thank you!
Awesome!!! But can you create a video that can send a push notification with the two devices
ОтветитьHi Simon
your videos are always very useful and engaging. Thanks
A question about push notifications.
Is it possible in some way to link the push notification to the user logged in to the app and not to the device? Maybe, alternatively:
1. generate a token with the data of the logged in user
2. generate a token, delete it on logout; generate a different one on new login ...
3 ... any idea?
Although absurd, it is possible that the user logs out and the device is used by another user who logs in. I have a shared device situation.
I would like to use pushes to sync the data with the backend and the data is user based.
Thank you very much
Monica
Useful after 3 days trying :(
Ответитьerror TS2305: Module '"@capacitor/core"' has no exported member 'PushNotificationToken'.
all of 3 pushnotification is import from @core/cap failed :(
Hello Simon, getting this : Module '"@capacitor/core"' has no exported member 'PushNotification'
could you suggest about it ?