Expo constants deviceId and installationId undefined - react-native

I am using Expo SDK 35 with expo-constants v7.0.0.
I used to get a value for Constants.deviceId but now it is coming back as undefined.
I Googled and saw that there is meant to be another property called installationId which superseeds this, but this is undefined also.
Can anyone shed any light? I need a unique ID per device/installation to identify the device on my server, is there any other expo library that can do this?
Thanks in advance

Expo.Constants.deviceId is deprecated and will be removed in Expo SDK 44, we will need to implement our own solution to keep track of device unique identifiers, see my answer here stackoverflow it will work for IOS and Android.

Related

Expo Pedometer "Getting step count for date range is not supported on Android yet"

When i updated expo SDK from 32 to 35, I get returned an error "Getting step count for date range is not supported on Android yet."
My code and google fit api configuration are clean. I know, because my app at google play store and it is working. Please help me, do you have any idea?
There seems to be an issue with Expo 35, where they forgot to reimplement Android function for getStepCountAsync... I guess we'll have to wait for Expo 36 to use it again!
In the meantime,
an option to use Pedometer with Expo 35 is described here

Background timer with Expo

Need to get the timer going even if the app is running in backgroung.
Trying to use react-native-background-timer library to do so, but getting this error:
undefined is not an object (evaluating 'RNBackgroundTimer.setTimeout)
On some research got to know that I will have to eject expo to be able to use this.
Is there a way to do this with expo?
Yes actually within Expo itself you can use their Background Fetch API to handle all background tasks, it uses TaskManager under the hood to do that. You don't need to use react-native-background-timer.
Further details of this API and application is found here.
Hope this Helps!

React native turn by turn navigation

we working with expo and using mapview, however, there are many restrictions in react native maps, as we are planning to implement turn by turn navigation. Integrating Mapbox would have been the best option, however we do not think it’s best to eject the project as expo doesn’t still support Mapbox. Although, I came across a package, react native maps navigation, I would like to know if anyone has been able to successfully implement it in their project and it functioned properly, and also know if there are any drawbacks that comes along with it. I am asking this because the author says “Please note that this module is usable but still under heavy development. Some properties and/or component names might change without notice.”
Kindly give your suggestions and advice. Thanks
Mapbox works very well in a react-native projects and recommend to use this service for your project but effectively, it don't works with expo so for me, you should eject your project to use it.
I paste here some packages I used for a GPS project (The last one is to get the current position of an user)
react-native-mapbox-gl/maps
mapbox-sdk
react-native-geolocation
Hope that could help you

How can we achieve coverflow view in android titanium?

I have seen that titanium support CoverFlowView in titanium but it works only on ios, Can anyone have idea to achieve CoverFlow in android with titanium
Thanks in advance
Looks like you are in luck! Someone already built a coverflow module for Android using the Android development environment.
https://github.com/moondroid/CoverFlow
You need to be willing to write the additional code for that to turn it into a module for Titanium.
http://docs.appcelerator.com/titanium/3.0/#!/guide/Android_Module_Development_Guide
It should be possible, but I must admit I've never tried to write one myself.
Basically you cannot get Coverflow on Android. Since it is a native iOs component which is not implemented in Android at all. Frameworks like Titanium always "link" your commands to internal system APIs. When there is no API there is no way to access it. Of course you could try to build it on your own but I think this would not work that well. And its a lot of work!
Additionally cover flow is not really useful (except for holding just a few items). Have a look at my question at ux.stackexchange.

Getting "Undefined" reading logicalDensityFactor on Android

I'm testing a Titanium App on an Android emulator.
I use dip units, so i need to know the Ti.Platform.displayCaps.logicalDensityFactor to get the propers numbers.
But when I try to read:
Ti.Platform.displayCaps.logicalDensityFactor
Ti.Platform.displayCaps.xdpi
Ti.Platform.displayCaps.ydpi
I get undefined everytime!
Someone knows why this happen to me? is the emulator or what?
Thank you
Found the solution!
The string is Case Sensitive and Titanium don't generate any error if you write it wrong.
Another problem is that Titanium suggest me
Ti.Platform.DisplayCaps
and not with a lower "D"
Ti.Platform.displayCaps
So if you get this error, make sure that you had write correctly the string!