How to do a persistent notification in React-Native? (Not swipeable) - react-native

I'm doing a "Uber like"app, and i want to do a persistent notification, as shown below, to let the driver know his status (connected, searching for rides, disconnected, etc). I've implemented push notifications trough Firebase, but they quite solve my problem, but it's not how i think is the best way. Does anyone know how to do that? WhatsApp implementation on what i want

Related

Use Firebase cloud messaging or let the app asks for event and fire notification with an API?

We are developing an app for Android and IOS for students. student can receive notification for upcoming events like exams or interviews.
We are between two decisions: Using FCM with the development of a backed which manages the sending of notifications and the registration of tokens or using the schedulers that exist in IOS and Android then download a list of events from an API regularly and trigger a local notification which will require less development on the backend side but a little more on the frontend side.
What would be best in your opinion and can we trigger a notification even if the app is closed for the 2nd solution?
I would deffinitely recommend to use FCM. It is much easier than it looks like and the performance of your notifications would be much better regarding stability, timing, battery persistance and other. You can use on of the Firebase databases to store the notification tokens and the Firebase Cloud Functions to send them from there. I have made a very similar App for Kindergarden children and it works great. I'm not sure if it would even work at all when you do it on your own. At least not as you expect it. For me that sounds like much more work.

How to trigger an UI action when the app is closed in React Native?

Apologies if my question is already answered in any other ways. I am very new to react-native with no knowledge of android or java.
I am trying to make a video conferencing app with react native. I used Agora for video calling and linked it with socket.io and react-native-callkeep for real time experience.
Now i am stuck in a situation where i have to make the app functional when someone is calling and the app is ""Closed"". Something like Whatsapp. I thought of implementing Firebase Cloud Messaging for push notification. And though it will open the application in someway. But the application opens when user opens the notification.
Can anyone please help me with any of the following or better ideas:
1. Keep the socket io open even when app is closed
Or 2. Open my application with incoming push notification (Without Opening It)
Please avoid abstruct answers as i am very new in this sector. I really appreciate the help. Thank you.
I think the second method is the way to go you can also look at this library called react-native-callkeep I think it fits your use-case as well.

Implement websocket notification in react-admin

I would like to notify a user when a specific record changes via someother process (outside of react-admin) in the backend.
For example, status of an order changes and I would like to notify user interested in that order right away in react-admin.
Does anyone have any experience doing this in react-admin? Is there a built-in way do this? If not, are there any resources I can review to implement it?
Thanks for your help.
I use a similar scheme. Using a custom saga that intercepts
various Redux actions and sends them through WebSocket:
https://marmelab.com/react-admin/Actions.html#custom-sagas
https://medium.com/#pierremaoui/using-websockets-with-redux-sagas-a2bf26467cab
https://redux-saga.js.org/docs/advanced/Channels.html
https://socket.io/docs/client-api/

Objective-C Async communication between IOS devices

Is there a way to perform async communication between iPhones/IOS devices? I have been researching and thought maybe APN might fill that void, but it sounds like I can't initiate an APN push from an IOS dvice to another, and even if I could I can't trigger the "event" on the other device with just an APN push from what I can identify.
Does anyone have any examples or general advice for IOS device interaction for devices that are not in GameKit (i.e. wifi/bluetooth) range that does not require an intermediate service (urban airship, dedicated server, etc) or will I need to have a 3rd party in order to trigger and/or sync these interactions between devices?
Sorry I don't have any code or details as this is still in the planning phases for me. Any pointers would be greatly appreciated.
The answer is : use a server side app and have all your devices talk to that server.
If you dont want or cannot host an app, you can use a cloud solution based on websocket like Pusher. You can then subscribe to events and post messages with data.
They have an iOS client library
http://pusher.com/docs/client_libraries
P.S: Also have a look at Parse and Stackmob , i remember that had this kind of feature was in their roadmap, but i don't know if it's available yet..
Hope this helps,
Vincent

How can my application perform a task when it is minimized or be started on certain events?

How can an application perform stuff when its actually closed like google+?
I notice that I got a notification from huddle chat from the google+ app for iOS. But google+ was actually not active, it was closed. Same situation with Whatsapp, I always get push messages both if the app is closed or active.
This kind of behaviour seems for me to be impossible to implement. From other questions I know that we cannot register some kind of background process. How do this apps handle that?
Can I still listen form something when my app is minimized?
When my app is just minimized but not closed I know that a certain method is called. Can I perform a repeating update task, e.g. read geo data?
The apps you mentioned use something called Push Notifications which work regardless of your App being open/in the background/closed. They are notifications sent to the device when an action happens and most of the processing is done on the Server (The notifications are not generated by the App itself. A server pushes the Notification on).
Apple has a fantastic section on Executing Code in the Background when your App is minimised which should provide most of the answers you need. It even has a dedicated section on explaining the Geo Data capture which should help you in this case.