First of all thank you for your time reading and maybe answering this question.
We have a react native app that uses react native Localize to handle i18n, and Firebase to handle notifications, those are sended in a PHP server.
We save the user´s locale (which we take from the phone) in our database after sign up. When we send the notification we translate it according to the users locale before sending it to the app.
But the user has the ability to change his phone language, so the notification might arrive in a different language because he has change it.
We first tought of checking each time the user loads the app if it´s locale has changed and update the bbdd field.
But we are not sure if this is a right approach.
How do you usually manage it?
I am having the same problem. I believe that other solution is offer the language setting inside your own app instead depend of operating system language, already see others apps making it.
With the language config inside your app, can you have total control of language to send push notification if you persists it in your backend.
Related
I'm trying to incorporate a feature into one of my apps that allows you to message users that are, at that moment, in and using the app. I've searched for a while now, but with no luck finding any article, API, npm package, etc, that supports this concept - if it even is possible.
I'd rather use an API than see when the user was last on the app via a timestamp and then "guess" if the user is still using the app.
I'm using React Native.
Check that AppState equals to 'active'.
https://facebook.github.io/react-native/docs/appstate
I'm developing an IoS and Android app using react-native, and am now starting to consider all the aspects of user registration, so that typically the person will provide some credentials, and then get sent an email (or possibly sms) enabling them to "verify" their account, after which point they are a registered user.
These registration processes (and subsequent emails/sms's seem to be fairly common , so I'm wondering if there are any API's which anyone has come across which make the job of creating the registration/activation process easier m rather than writing code from scratch ?
Many thanks in anticipation
It depends what you want when you ask for an API. If you're developing backend as well you can use Auth0.
If you want just to implement frontend, I guess you have to write your own code. Consider using something like redux or mobx to store your email and other things after logging in.
Anyways the REST part you have to write on your own. As for views you can google for it, for example there's react-native-login-screen
Is there a way to get locations history, or at least have a service to track if user visited certain location.
We want to try to track if the consumer will re-enter the location, even when app is closed.
Starbucks does that (when you're near Starbucks cafe, they send special deals based on that specific Starbucks cafe)
There is a Frequent Locations in iOS, how to get that in react-native?
Update:
Watching location is not the case, as it requires app to be active
You can use geolocation to listen to a user location. Whenever he enters the location you want, you can trigger a function to do whatever you want.
You can find more details of how to implement it in the official docs:
https://facebook.github.io/react-native/docs/geolocation.html
Hope it helps.
Your answer is Geofences. Geofences are an easy way to create an area and check if user has entered, exited and stayed or not. The app works in "terminated" mode as well provided that it has required location permission.
For iOS, you can use the Geolocation framework. I'm hopeful that react-native has a library to use that framework. If not, you can write native code and use it by building native module.
Does anyone know how to access Contacts in Windows 8 Store apps?
I know that because of the sandboxed nature, Windows Store apps cannot access AddressBook from files such as Outlook Express contacts or Outlook, but since there is already an app called People that comes pre-installed, I figure why not let users make use of whatever Contacts the user has already allowed the app to see, rather than creating separate list of Contacts for my app. It seems silly to recreate the wheel by asking the user to re-import all the contacts again.
I have seen Contact Picker example but I still have no clues how to get list of Contacts/People as in that People app.
I have not developed for mobile phone, however if the device is a mobile phone, surely the app is expected to use local contacts rather than keeping separate list of contacts. So I am thinking there's got to be a way to do the same thing on a PC or any device really, rather than each app managing its own contacts. I have not seen any guidance on how to do this. What are your thoughts?
I asked a similar question a few days ago and, after a lot of research, it looks like it's just not possible to get that information from the people app outside of the contract. The reason that it works within calendar/mail/messenger is because they're all technically contained within the same app and are able to use each other's data and violate normal rules.
A lot of people have pointed me to look at the live SDK, but it still seems like it's not at all possible to get people information in your app, since the SDK doesn't support it anymore.
Look at the ContactPicker class :
http://msdn.microsoft.com/en-us/library/windows/apps/br224913.aspx
Another way is to share your resource or whatever you want to send and user will choose an app that will send or on any another way use your shared resource (url, image, whatever)
IMO the latter is preferred way since then user will have a choice of applications that can send mail or post that resource on facebook / twitter.
Check this sample on ContactPicker
Do I need to implement functionality within my app to check the store for newer versions, or is this done for you automatically? If I do need to do this, how would I go about it?
Its done automatically by the app store. When the user enters to the App Store on his iPhone and theres a new version the "Updates" count will increase and notify the user.
Some like posting this stuff as Push notifications for the user, but many users don't appreciate it much :)
This is all handled by the App Store. You don't need this.