Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [react-native]

React Native lets you build mobile apps using only JavaScript. It uses the same design as React, letting you compose a rich mobile UI from declarative components. The focus of React Native is on developer efficiency across all the platforms you care about - learn once, write anywhere.

Filter by
Sorted by
Tagged with
0 votes
0 answers
85 views

React Native (expo) mobile application publishing to stores in Azure DevOps pipeline using different backends for different app versions

Mobile development is quite new for me, and I would like to ask about a solution review. I'm not sure the way I publish the application is correct, I think good companies may do it differently. I have ...
alcohol is evil's user avatar
1 vote
0 answers
20 views

Is this component file format for react native good?

I'm new to React Native. I wonder if the following project file structure is ok to use for the rest of my project. Here is an example of component: ...
João Hamerski's user avatar
2 votes
1 answer
99 views

Move timestamp to the next Monday 10:01 AM [closed]

I've been battling ChatGPT for hours now and can't get satisfied with this simple algorithm in TypeScript. These two (hopefully correct) TypeScript+ReactNative solutions should move the timestamp ...
Slazer's user avatar
  • 121
1 vote
0 answers
36 views

Good way to coding on React-Native?

I'm new on this field of coding, and I start to create by myself a project for iOS and Android. I'm a bit lost of how I supposed to organize my code, I saw different persons on YouTube doing their ...
Dorian's user avatar
  • 11
-1 votes
1 answer
62 views

Preferable ways for reusing input components in react native? [closed]

I am using react native 0.68.5 When I call the renderReusableTextInput method in Main.js I am sending all the styles including ...
CodeLearnerBoy's user avatar
1 vote
0 answers
57 views

React Native app with context - Search and Report functionality

I have a react native app. I have a search component, that I reuse in the SearchScreen (where I search for train stops) and again in my Report screen where I report (and first search station) not ...
juliascoding's user avatar
1 vote
1 answer
424 views

React Native login, sign up and sign out using Firebase project

I have built a basic app which uses firebase for authentication. The app is pretty simple. Sign up the user to firebase using email and password. Sign in the user Sign out the user Also, I have ...
DeveloperLV's user avatar
1 vote
0 answers
40 views

Using React Native to implement Conway's Game of Life

I'm using React Native to implement Conway's Game of Life as a mobile phone app. So far I've implemented the game logic and a main screen with an embedded GLView component where the game board is ...
Ste1891's user avatar
  • 31
1 vote
1 answer
52 views

Typescript React-Native Component Dimension Hook

I did a lot of research trying to find a React Native component which could reference its own dimensions in order to scale different elements in its style, but could not find any solid examples. I ...
Austin Brown's user avatar
2 votes
1 answer
98 views

Abstract navigationOptions react navigation

I have many stacks with the same navigation options. How do I abstract the navigationOptions part to have it repeat in all my stacks? ...
manuelBetancurt's user avatar
0 votes
2 answers
109 views

React Native screen to add a city to a weather app using a REST API

In a recruitment process, the company gives me a project to do in react native. I finished all the tasks. But company gave me a feedback and said that your project was good, but you did not apply best ...
leo giovanni's user avatar
2 votes
1 answer
170 views

React component to render price change

I've written this Card component which is composed of thumbnail image, name, symbol, ...
Penny Liu's user avatar
  • 123
0 votes
1 answer
25 views

react native refactor theme handling

I am styling my react native component according to some conditions, here the code, The question is how do I make this cleaner? functional style? ...
manuelBetancurt's user avatar
0 votes
1 answer
24 views

JS react manage dark mode ternary

How to choose the dark mode properly? ...
manuelBetancurt's user avatar
1 vote
0 answers
15 views

react string replace {image0} with actual image ramda?

I can feel the following is definitely not the optimal nor the cleanest way to do this. But I'm not quite sure how to refactor this. ...
ochitos's user avatar
  • 193
2 votes
1 answer
121 views

Managing redux state of mutiple switch components

I have a react native native app and I am fetching the state of the toggle buttons from an API and then putting them into redux state. I do not like the way I have implemented it cause it seems very ...
Great Khan 2016's user avatar
5 votes
1 answer
12k views

React hooks update array of object

I have declared a react hook which will contain an array of object as follows: const [rowDataTracker, setRowDataTracker] = useState([]); Now I need to update the ...
kukuha's user avatar
  • 53
4 votes
1 answer
46 views

Clean up and Refactor react code to increase performance

I am new in coding in React and I have just joined a new organization where I need to send my code for review .The functionality is working fine but it seems to me that code in my component has become ...
Gitesh's user avatar
  • 143
2 votes
1 answer
45 views

Displaying information from shops

To display all the shops, I get data from a database (Firestore) and push them into array and setState, and use map to display shops from ...
Wes's user avatar
  • 21
2 votes
1 answer
277 views

How to change the text in the flatlist items with improved performance?

I am working on a react native android app that generates fancy text. Similar to this Fancy Text Generator For every letter being typed fancy text will be generated. I implemented everything and it ...
AzizStark's user avatar
  • 123
4 votes
1 answer
109 views

React-native component

I've written this react-native component which is giving me a bad feeling that it's not as good as my expectations. I want to make it look cleaner with smart and less code. ...
Hossein Zare's user avatar
3 votes
1 answer
169 views

Minimize Hard Coding in React Native

Can anybody help me to minimize my hard coding? Also please give me any suggestions for improving my code for the future? My Source Code: ...
Jasur Kurbanov's user avatar
5 votes
1 answer
68 views

How can I implement this React Native component without relying on a conditional statement?

I have a component, it's actually an entire screen in my application. This screen/component renders multiple other components. However, what it renders is conditional. Currently, I have an if ...
Fabian's user avatar
  • 53
1 vote
0 answers
279 views

React Native form for entering one-time password [closed]

Here is the React Native code to optimize: it's an OTP form. I want it to be as small as possible. ...
droid's user avatar
  • 111
1 vote
0 answers
104 views

React Native Lazy Collapsible Panel

What is it? React native Accordion Collapsible Panel. You pass the summary (always shown bit) and the detail (sometimes hidden bit). If the detail is passed as a function or promise (ie async ...
Nathan's user avatar
  • 647
2 votes
1 answer
63 views

Date prompt React.js component

I have created a date component (working GIF at the bottom; please ignore the styling). There isn't a problem with the working of the code but rather the code I wrote seems messy and something hard ...
iRohitBhatia's user avatar
5 votes
1 answer
62 views

Comparing 2 iOS and Android versions

Please review and let me know which version is better. I'm just trying to find any caveats or better ways to accomplish the a version comparison independent from Android and iOS. Formats accepted: '1....
Vincent's user avatar
  • 51
3 votes
1 answer
630 views

React code to build shopping cart

I have built a basic shopping cart simulator. All it does is add and remove items between two different basket (i.e. aisle vs basket). While working on the problem I started to think about the ...
Mad-D's user avatar
  • 131
1 vote
0 answers
693 views

React Native app screen for booking appointments

I've been building a two-sided (both clients and service providers would use the app) appointment booking app. This is a screen from which a service provider can confirm their profile after having ...
user2717129's user avatar
5 votes
1 answer
817 views

Creating directory within Application Support, and preventing iCloud backup

I'm using react native to build an iOS app, but have little to no experience in obj C or iOS development. The app I'm building has a bunch of content files that aren't user specific, will be ...
Ben's user avatar
  • 51
2 votes
0 answers
3k views

Get count of unread messages from google firestore

I am creating an app (with react native) on where messages can be viewed. On the home screen you can see a badge with the unread/new messages. It shows the badge (after a short delay, you will see ...
udarts's user avatar
  • 121
3 votes
0 answers
915 views

React native circular progress view

This is a functional component that I have developed in React Native for creating a circular progress view. The code does not use any external libraries, just pure CSS. Article that I wrote while ...
Saurabh Gour's user avatar
0 votes
2 answers
296 views

Common styles in React-Native

Background: I am completely new to react-native. Question: Is there any reason why I shouldn’t do this from an experienced point of view? Goal: - have common styles in my react-native app? - use ...
Defrian's user avatar
  • 113
1 vote
0 answers
4k views

Custom header with React-Navigation and React-Native-Paper

Thanks to the discussion in this issue combined with issue 1886 and issue 716 and issue 570 I was able to integrate the Toolbar of react-native-paper and with react-navigation. As I am quite new to ...
Defrian's user avatar
  • 113
0 votes
1 answer
846 views

Using a destructuring assignment on a style object to extract two members

Recently, one of my colleague decided to destructure the React-Native styles object this way: ...
alexmngn's user avatar
  • 101
2 votes
0 answers
51 views

Create exact replica of react component with different name

I have a react native component called "width". It has 3 width values which have associated <TextInput>s which map to the redux store as ...
user2602079's user avatar
1 vote
0 answers
455 views

Squares with different background colors

Titles is an array populated by numbers (1, 2 and 3). Depending on the number, a Square component should have a different ...
Wasteland's user avatar
  • 547
2 votes
0 answers
1k views

Small camera app in react-native for Android

I'd like you to help me review a small camera app. Most of the code comes from here; I just changed it a little bit. I started dabbling with react-native for the first time. It seems kinda neat but I ...
user's user avatar
  • 255
7 votes
1 answer
3k views

React Native - Combining login and signup pages into one component

I have been building an app in React Native and have decided that since my Login and Signup components share much of the same ...
szier's user avatar
  • 315
7 votes
0 answers
4k views

React Native - Rendering different scenes based on application state

I am using react-native-router-flux to organize the routes for my application. Using Firebase, I am able to call ...
szier's user avatar
  • 315