Questions tagged [expo]
Expo is an open-source and free platform that lets web developers build truly native apps that work across both iOS and Android by writing them once in just JavaScript. Use the Expo tag on questions about developing Expo projects and using the Expo development tools like XDE and exp.
16,526
questions
358
votes
38
answers
493k
views
Hide header in stack navigator React navigation
I'm trying to switch screens using both stack and tab navigator.
const MainNavigation = StackNavigator({
otp: { screen: OTPlogin },
otpverify: { screen: OTPverification},
...
351
votes
12
answers
183k
views
What is the difference between Expo and React Native?
From the Expo website
Expo lets web developers build truly native apps that work across both iOS and Android by writing them once in just JavaScript.
Isn't this what React Native does? What's the ...
204
votes
19
answers
152k
views
Error Appstore connect : Missing Purpose String in Info.plist File
I've submitted my app for review to the App Store Connect. Although the app is still under review, I've received an email to inform me that I have to fix an error. Here is the content of the message:
...
148
votes
7
answers
116k
views
Cannot add task 'wrapper' as a task with that name already exists
When installing 'react-native init AwesomeProject' I get this error when I run react-native run-android:
Could not determine java version from '11.0.1'.
A quick google suggests I need to update the ...
136
votes
9
answers
240k
views
How can I clean (reset cache) of React Native using Expo. Not sure if it is cache issue
I am building a simple React Native app with create-react-native-app using only react-navigation and base-64(base 64 encode/decode) as dependencies. Over time starting the app became slower and now ...
108
votes
17
answers
57k
views
Xcode 15: Unable to boot the Simulator
I was able to run iOS simulator fine with Xcode 14 and my Mac recently updated the latest version of Xcode which is 15 then I'm no longer able to boot a device from its new simulator.
I did try many ...
107
votes
16
answers
159k
views
React Native iOS and Android folders not present
I'm new to react native, and I've been having some trouble understanding the folder structure of the app which should supposedly be present in the project folder on creation. Basically, when creating ...
91
votes
3
answers
49k
views
Warning : Failed child context type: Invalid child context 'virtualizedCell.cellKey' of type 'number' supplied to 'CellRenderer', expected 'string'
I updgraded from react 16.2 -> 16.3-alpha-1 and react-native 0.52->0.54 and I get the warning above in the simulator.
90
votes
21
answers
155k
views
npm ci can only install packages with an existing package-lock.json or npm-shrinkwrap.json with lockfileVersion >= 1
This is the issue that I am facing when running the command npm ci to install dependencies in my GitHub Action file.
I am working on an expo managed app and using GitHub Actions as a CI for triggering ...
85
votes
39
answers
107k
views
Network Response Time Out Error (create-react-native-app) (expo)
I am trying to run create-react-native-app on expo app in android.
Firstly ,I created the project by writing command
create-react-native-app test
then I executed
npm start
then scanned the qr ...
76
votes
14
answers
45k
views
Expo: Change default IOS simulator
I am new in expo and react-native
Whenever i run the app from IOS simulator (inside expo) it always boots up the IphoneX. If i need to change the simulator,I have to open it through Xcode, is there ...
74
votes
10
answers
117k
views
Implement pull to refresh FlatList
please help me out to implement pull to refresh on my app, I'm kinda new to react native, thanks. I don't know how to handle onRefresh and refreshing.
class HomeScreen extends Component {
state = { ...
68
votes
0
answers
48k
views
What is the difference between Expo CLI and React Native CLI? [duplicate]
React Native provides two way to create Project.
First:
npm install -g expo-cli
Second:
npm install -g react-native-cli
so what is different between them and what should be used if we create ...
66
votes
12
answers
194k
views
How do you format a number to currency when using React native Expo?
How do I take a number like 10000 and have it output as $10,000.00?
I even had a problem with String.format(...) with a Not a function error.
I followed numerous articles, all incomplete and none ...
59
votes
20
answers
136k
views
'expo' is not recognized as an internal or external command
After running npm install -g expo-cli and successfully installing the packages globally, expo is still not recognized as an internal or external command. Does anyone know how I might get around this ...
58
votes
3
answers
84k
views
Invariant Violation: requireNativeComponent: "RNCSafeAreaProvider" was not found in the UIManager [closed]
Implementing React Navigate in the project installing the package npm install @react-navigation/native @react-navigation/stack shows the following error.
Can anyone help me with this issue?
57
votes
14
answers
56k
views
Getting Error: "Use process(css).then(cb) to work with async plugins"
screens/HomeScreen.js: Use process(css).then(cb) to work with async plugins
Here is my HomeScreen.js
import { View, Text } from 'react-native'
import React from 'react'
export default function ...
54
votes
20
answers
66k
views
NativeModule: AsyncStorage is null, with @RNC/AsyncStorage
I'm working on a React Native project created with Expo. I've been using regular old AsyncStorage, importing from react-native, and all has been well.
In looking up how to mock AsyncStorage for ...
53
votes
11
answers
66k
views
How to reduce the size of an expo/react-native app on Android
I am developing a small dictionary app by using react native with expo.
As I am compiling to Apk file. The size goes up to 30mb and after having installed on a device, it goes to 80mb.
Is this ...
52
votes
15
answers
54k
views
EXPO: Unable to resolve module ‘./debugger
After a reload my app has stopped loading.
a
I have tried on both emulators and 2 real devives, android and ios.
The error is:
Error: Unable to resolve module ./debugger-ui/debuggerWorker.d9da4ed7 ...
50
votes
9
answers
37k
views
expo + react-native: There was a problem sending log messages
I am building a react-native app that I recently moved to expo. The app seems to display the expected screen, but before it completes, I am receiving the following error message: console.error: "...
50
votes
10
answers
33k
views
React-native bundling failure. ERROR MESSAGE: "While trying to resolve module 'idb'..... Indeed none of these files exist":
ERROR MESSAGE IN QUESTION:
While trying to resolve module idb from file C:\Users\OG\Desktop\programming\react_native\mealstogo\MealsToGo2\node_modules\@firebase\app\dist\esm\index.esm2017.js, the ...
50
votes
17
answers
47k
views
Calling locally hosted server from Expo App
I am creating a react-native app and one of the components I have created contains a property which is populated through data coming from an http request.
Right now I am hosting the server from my ...
50
votes
10
answers
168k
views
React Native: Generate .apk and .ipa using Expo
I'm trying to generate a .ipa and a .apk file for my React Native app using Expo & Create React Native App. I successfully built the app and was able to get it to run on both an iOS & an ...
47
votes
12
answers
22k
views
react native downloading javascript bundle 100% stuck
when I am trying to execute npm start it works fine, but when i try to run my application by expo the process goes till 100% and after that nothing happens. I am not getting what is exact issue over ...
47
votes
9
answers
24k
views
EAS Build iOS Failure: Authentication with Apple Developer Portal failed [closed]
I'm using EAS to build my Expo app, and today I started getting this error when attempting to run an iOS build, either local or on EAS servers. I'm thinking it's an issue with Apple servers, so I'm ...
45
votes
38
answers
157k
views
Can't load expo app: Something went wrong
I've created an expo app with exp init MyApp command and started it by running exp start in MyApp directory.
Then I'm scanning barcode which was printed in console with expo mobile app on android ...
44
votes
3
answers
32k
views
App Store - Help answering "Missing Compliance" (using Expo + Firebase)
I'm publishing my app to App Store and I have doubts regarding the "Missing Compliance" step.
Here's some info about the app:
I used Expo (Managed workflow). That means I don't have direct ...
42
votes
6
answers
62k
views
How can I upload a photo with Expo?
I'm making an app with Expo and want to let the user take a photo or pick one from their camera roll and upload it to my server. How do I do this?
42
votes
6
answers
16k
views
'Stack.Navigator' cannot be used as a JSX component
There is a type issue using react navigation, when use Stack.Navigation or Stack.Group from createNativeStackNavigator
The issue saids that the types dont match with JSX.element at the end of the ...
41
votes
10
answers
55k
views
How to define entry point for react native app
I'm just getting started with react native and have created a base app with create-react-native-app.
I did some restructuring and made a few new folders and renamed the App.js to Home.js. I modified ...
41
votes
7
answers
66k
views
How to reduce Android APK size in react-native?
I am working on react native project , but whenever i am building an Apk file , it give me Apk of 47MB.
I tried every documentation which i found useful on google but nothing works for me, Is there ...
40
votes
15
answers
67k
views
React Native Expo change default LAN IP
I've got virtual box installed. And when I look at the host > LAN > ip address is exp://192.168.56.1:19000.
How can I change it without disable the network? because it's my virtualbox ip and my ...
40
votes
11
answers
49k
views
How to fix Something went wrong installing the "sharp" module and Cannot find module '../build/Release/sharp.node' in expo
I tried to install expo after I executed the command exp start but I got:
Something went wrong installing the "sharp" module
Cannot find module '../build/Release/sharp.node'.
How can I fix ...
38
votes
16
answers
111k
views
Uninstalling Expo CLI
I have installed Expo CLI globally and cant start a new react native app without using expo cli and therefore would like to uninstall it from my system. I have spent hours trying to work out how to ...
36
votes
13
answers
11k
views
Android Material and appcompat Manifest merger failed in react-native or ExpoKit
I updated 'android.support:appcompat-v7' to 28.0.0.
But it brought an error from the build.
Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com....
36
votes
5
answers
10k
views
RTL is forced in RTL devices
The new version of React Native has issued support for RTL devices:
https://facebook.github.io/react-native/blog/2016/08/19/right-to-left-support-for-react-native-apps.html
However, it seems that in ...
35
votes
6
answers
47k
views
Re-render component when navigating the stack with React Navigation
I am currently using react-navigation to do stack- and tab- navigation.
Is it possible to re-render a component every time the user navigates to specific screens? I want to make sure to rerun the ...
34
votes
4
answers
81k
views
Change navigation header background color
Struggling to understand how to change the navigation header bar background color.
I'm Using react navigation and Expo to build my app.
backgroundColor does not seem to do anything. Any idea how to ...
34
votes
3
answers
86k
views
How to remove unwanted expo modules
When creating an react native app with expo, expo installs many module that i don't need. Is there a way to remove these unwanted modules like barcode reader google sign in and google maps.
thanks
34
votes
2
answers
16k
views
Not using the Expo fork of react-native
I'm using expo with react native. All is fine, but i get this warning and the app takes a long time in loading :
[exp] Warning: Not using the Expo fork of react-native. See https://docs.expo.io/.
...
33
votes
4
answers
19k
views
Camera Preview in Expo is Distorted
I'm using Camera that comes from expo package and I'm having trouble with camera preview distortion. The preview makes images appear wider in landscape view and thinner in portrait view. Most of the ...
32
votes
16
answers
63k
views
Failed to install expo package with error: yarnpkg exited with non-zero code: 1 yarnpkg exited with non-zero code: 1
Im currently trying to update my Expo SDK from 36.0.0 to atleast 37.0.0 with the command expo update
however im getting the error:
× Failed to install expo package with error: yarnpkg exited with ...
32
votes
4
answers
55k
views
How to build expo apk using eas build
After updating expo it no longer supports building apk files using expo build:android -t apk and instead advices to using eas builds using the command eas build -p android --profile preview but it ...
32
votes
7
answers
27k
views
How to use import with absolute paths with Expo and React Native?
I'm trying to use absolute import paths instead of relative paths with Expo and React Native.
I looked on the expo docs and couldn't find an answer... Searching for the subject in react community I ...
32
votes
6
answers
61k
views
How to build Expo APK local
Is it possible to build the APK of an expo app locally?
The doc says:
If you haven’t used exp before, the first thing you’ll need to do is login with your Expo account using exp login.
I tried ...
32
votes
4
answers
30k
views
Scroll through the view when keyboard is open (React Native / Expo)
I am having a hard time using a KeyboardAvoidingView on my Expo app. I would like to meet the following requirements:
When the keyboard opens, the view should scroll up so that the user always sees ...
31
votes
5
answers
29k
views
Error: NativeViewGestureHandler must be used as a descendant of GestureHandlerRootView
I've installed GestureHandler (npx expo install react-native-gesture-handler) and also imported it into my App.tsx file on line 3 with polyfills
import 'react-native-gesture-handler';
was doing it by ...
31
votes
8
answers
32k
views
crypto.getRandomValues() not supported
I'm getting this error with npm [email protected] when I try to generate a QR code with react-native-qrcode-generator
I'm using react-native with an expo managed workflow. And the thing is ...
31
votes
1
answer
4k
views
expo.io's BackgroundFetch is not running the defined task
I am currently developing an app for iOS with expo sdk-version 32. I have to call a REST service periodically from my app. In order to do that I tried to utilize the new BackgroundFetch API.
Here is ...