How to view realm db created by react-native in ios stimulator - react-native

I want to access realm database created by my ios app that I created using react-native. Its easier to use adb pull for android but for ios I am not getting much idea. There are some links like -
realm-file in ios app
to find app uuid for above link
So any help, how to view realm db for developing and debugging purpose for react-native developed ios app.
Thanks for the answer but additional (out of curiosity) Question - but how to find app uid which are installed by react native on ios simulator ??

While searching through the web, got the answer in docs:
console.log('realm db file path:', realm.path);

With the iOS emulator you can just find the path and open the Realm directly (which allows you to see the changes as they happen, great for debugging), on Android you will have to copy the file out to the regular file system.
It is all described in the docs for Realm Studio: https://docs.realm.io/platform/realm-studio/view-your-data#viewing-realms-from-emulators

Related

Expo: Remove iPad support on non published app

I'm completely new to React Native, Expo and App development in general.
I'm building a React Native app solely for iOS using Expo. I've finally managed to finish a version I'm happy with, tested with users etc. I've now been spending time adding all the required screenshots, text, info etc to App Store Connect in order to submit the app. While doing that, I learned that iPad app screenshots was mandatory, which I found weird.
I later found that I had "supportsTablet: true" in my App.json file, so it makes sense that it's expecting iPad pictures. After changing this and making a new build and submitting that, it's still a requirement.
After Google a bit I can see that it has been impossible to change this:
Removing iPad support from app
iOS App Submission : remove iPad support
iOS App Submission want to remove iPad support
This led me down the road of trying to upload the app as a new submission. I can't get this to work though. According to this documentation:
https://developer.apple.com/library/archive/qa/qa1623/_index.html
I should change bundle identifier and upload again. Changing this in app.json under expo.ios.bundleIdentifier doesn't work though, as I just get an error that I've already uploaded this app previously.
What are the steps I should do to reupload the app as a new submission, so that I can not support iPad?
In order to upload a new version, you must increase the version and the build number. You can find this if you open the project in Xcode under the General tab and the Identity section. In the same tab, you will see the Deployment Info section where you can untick the iPad. Check the picture attached.

Screenshot Lock not working in React native app on iOS devices

We want to lock screenshot on app screens in React Native app so that user is not allowed to take the screenshot. The feature is implemented successfully in android version of the same React Native app. But it is not working in iOS app which is published to app store. I have also tried react-native-prevent-screenshot plugin but that is also not locking screenshot in iOS version. I even implemented blurred view on appDelegate.m file to prevent screenshot capture in app, but even this did not have any impact. Can someone tell if Apple has banned this feature completely or there is possibility of some issue in coding. But I rule that out because it is working successfully in android apk. Please help

React native automatic update from store

Hi guys I need my react native app to update it self automatically (with user consent) when new version is published to the store (both android and ios)
I need the app to download the apk or ipa and complete the update process, not using CODE PUSH or OTA,
is it possible?
The app itself can't do that.
The closest thing you can do is:
Verify app version against the version on the server (if you have a back end).
Present a button to the user which will open the app store off your platform directly at your app's page, using deep linking.
You will have to keep server and deployed app versions in sync.

Is Expo able to build a production-ready iOS app without needing a Mac?

I'm about to start developing a React Native app. However, for iOS, my company is unable to provide me a physical Mac device for building/publishing the app.
So I'm planning to use Expo. But can Expo replace a physical Mac for building the app (I mean, getting the app ready for the App Store) ? Or is Expo only used to test the app on an iPhone (by flashing the QR code) ? I'm a bit confused.
Short answer: Yes, with a curve.
Long answer:
Before your app is released, react native needs to transpile your javascript to exo-native code (not sure of the real term for that). And this process may not run unless you 'eject' your code. This produces the android and ios folders that would be almost production ready except that you now have to build to generate apk in the case of Android or app in the case of iOS.
Now if you have added third party plugins, that have native codes, that expo does not already have a unimodule for, these won't work in expo because they need to really be compiled into native codes before being bundled into your app.
Edit:
Expos has evolved during these years and the former short answer I gave as No, no longer is as valid. You can now build without a Mac; expo does that for you.

Does Expo required a internet connection for React native build?

So I just finish the project, detached, using expoKit. Uploaded it to the testflight. And it pops out an error message said:"This experience uses an unsupported version of Expo(v22.0.0)..." So I re-publish my project in Expo XDE and the error message gone.
Now I am just confused, dose expoKit require a user to have an internet connection to use the app in order to download data from expo server?
What does expo really do?
you need to clear cache and storage in setting in emulator for expo.
in ur emulator go to settings/apps/expo/storage/clear...
it will work right now.
br
Yes, expo required internet connection, it will generate link and you need to open it in your device to see output
from it's doc
Expo apps are React Native apps which contain the Expo SDK. The SDK is a native-and-JS library which provides access to the device's system functionality (things like the camera, contacts, local storage, and other hardware). That means you don't need to use Xcode or Android Studio, or write any native code, and it also makes your pure-JS project very portable because it can run in any native environment containing the Expo SDK.
for more please see https://docs.expo.io/versions/latest/ and https://docs.expo.io/versions/latest/guides/up-and-running.html