Skip to main content
Filter by
Sorted by
Tagged with
925 votes
45 answers
428k views

What is the difference between React Native and React?

I have started to learn React out of curiosity and wanted to know the difference between React and React Native - though could not find a satisfactory answer using Google. React and React Native seems ...
shiva kumar's user avatar
  • 11.4k
717 votes
38 answers
462k views

Hide keyboard in react-native

If I tap onto a textinput, I want to be able to tap somewhere else in order to dismiss the keyboard again (not the return key though). I haven't found the slightest piece of information concerning ...
TurboFish's user avatar
  • 8,169
717 votes
8 answers
233k views

What is the difference between using constructor vs getInitialState in React / React Native?

I've seen both used interchangeably. What are the main use cases for both? Are there advantages / disadvantages? Is one a better practice?
Nader Dabit's user avatar
  • 53.5k
655 votes
41 answers
1.1m views

How can I insert a line break into a <Text> component in React Native?

I want to insert a new line (like \r\n, <br />) in a Text component in React Native. If I have: <text> <br /> Hi~<br /> this is a test message.<br /> </text> Then ...
Curtis's user avatar
  • 6,562
623 votes
37 answers
588k views

React Native Error: ENOSPC: System limit for number of file watchers reached

I have setup a new blank react native app. After installing few node modules I got this error. Running application on PGN518. internal/fs/watchers.js:173 throw error; ^ Error: ENOSPC: System ...
Badis Merabet's user avatar
600 votes
35 answers
592k views

React Native android build failed. SDK location not found

I have error when i start running android What went wrong: A problem occurred evaluating project ':app'. > SDK location not found. Define location with sdk.dir in the local.properties file or ...
Pyae Sone Nyein's user avatar
480 votes
37 answers
536k views

How to do logging in React Native

How can I log a variable in React Native, like using console.log when developing for web?
ljk321's user avatar
  • 16.7k
474 votes
17 answers
142k views

Error Running React Native App From Terminal (iOS)

I am following the tutorial on the official React Native website. Using the following to build my project: react-native run-ios I get the error: Found Xcode project TestProject.xcodeproj xcrun: ...
JacobSiegel's user avatar
  • 5,381
427 votes
56 answers
444k views

Unable to load script from assets index.android.bundle on windows

I'm trying to run my first React Native project for first time on my device (Android 4.2.2). And I get: unable to load script from assets index.android.bundle Commands that I used: cd (project ...
Goba's user avatar
  • 4,415
401 votes
10 answers
117k views

What is the difference between Hot Reloading and Live Reloading in React Native?

I'm a bit confused here. When I'm debugging a React Native Application, I usually enable both Hot Reloading and Live Reloading. I want to know what is the difference between them?
Raman Choudhary's user avatar
379 votes
16 answers
364k views

How to use comments in React

How can I use comments inside the render method in a React component? I have the following component: 'use strict'; var React = require('react'), Button = require('./button'), UnorderedList = ...
user avatar
367 votes
6 answers
205k views

What are my options for storing data when using React Native? (iOS and Android) [closed]

I am still new in the React Native world, and generally in the mobile/native world as well, and I am finding the documentation a bit lacking when it comes to data persistence. What are my options for ...
Sia's user avatar
  • 9,193
360 votes
38 answers
501k 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}, ...
Avijit Dutta's user avatar
  • 3,831
358 votes
17 answers
242k views

How to add icons to React Native app

I am making a React Native app. I would like to customize the app icon (meaning the icon that you click on to start the app). I have Googled this, but I keep finding different types of icons that ...
Adam Katz's user avatar
  • 6,925
351 votes
73 answers
324k views

Unable to load script.Make sure you are either running a Metro server or that your bundle 'index.android.bundle' is packaged correctly for release

react-native run-android command terminates by leaving a message in android simulator. The message is as follows: Unable to load script.Make sure you are either running a Metro server or that your ...
Belle Solutions's user avatar

15 30 50 per page
1
2 3 4 5
9468