Quantcast
Channel: Active questions tagged react-native+typescript - Stack Overflow
Browsing all 6366 articles
Browse latest View live
↧

How to extract date and time from ISO into local date and time [duplicate]

I have a date and time in ISO"time": "2021-10-28T17:30:00.000Z"Below is what I am doing right now to extract the date and time:var dateExtract = time.substring(0, 10);var timeExtract =...

View Article


Can i use two mergeMap together in RxJs

I have been started using RxJs with redux and i have created a stream which is working. Here's my action pipe:action$.pipe( ofType(DELETE_CALL_HISTORY), withLatestFrom(state$), mergeMap(() =>...

View Article


How to create and download .ics ICalendar file for multiple events in spfx...

I have created a spfx react application for calendar where I need to export the calendar events i.e. to download the calendar events as .ics file on button click.Note:- I need to to export multiple...

View Article

Test render in ReactNative with Jest and reactnative-testing-library: You are...

I have a problem when I try to test render method in my ReactNative application with EXPO, I am using JEST and reactnative-testing-library.This is my code:import { render, fireEvent, cleanup, wait }...

View Article

How to setup customized vs code debugger for mono repository

My project directoryMy ProjectClient/react UIServer/ Nodejs with TypeORMMobile UI/ React NativeHow do I customize vs code debugger for this project.

View Article


Styling only to last index of an Array in typescript React?

The only idea I have now isif (customFields.values[0]) {<View style={styles.borderContainer} />; } For this arraylet customFields: Array<{ value: any; label: string; }> = []; if...

View Article

Image may be NSFW.
Clik here to view.

React-Native Warning: Overwriting font Family style attribute preprocessor

I'm getting the following warning:"Overwriting font Family style attribute preprocessor" coming out from StyleSheet.js when running the app on iOS simulator. I haven't tested on Android yet...

View Article

Unable to re-render view in React Native project (functional component)

I am currently learning React.After reading the docs and trying some examples, I still couldn't figure out how to make this code work:Issue:View not re-rendering after data fetched/state changed.The...

View Article


Add strong typing for react navigation props

I'm using typescript in my react-native project(expo).The project uses react-navigation, so on my screens I can set navigationOptions and I have access to the prop navigation.Now I'm trying to strongly...

View Article


how to set global variable in React Native in typescript?

I want to set a global variable in react native. It is neccessary and seems like only option in my particular usecase. I'm using typescript with my project. The problem is typescript complains when I...

View Article

Image may be NSFW.
Clik here to view.

How to blur image with affecting his shadow? [duplicate]

How to blur image with affecting his shadow like this image.In CSS, it gives me something like this:filter: blur(100px);And I don't want to get this:backdrop-filter: blur(100px);Before:After (what I...

View Article

Jest (ESM) issue loading files from React Native in unit tests

Running Jest with full ESM support (now available!) and TypeScript using ts-jest as described in thedocs. It's working beautifully well! Until I try to use it with React Native.In any tests that have...

View Article

How to know which iteration of the array.map I'm on?

I'm new to react-native.I want to use array.map() to render out some jsx in the UI.I'm looping over the API response which is as follows:chosenProducts = [{id:1 , name:"carpet"} ,{id:24 , name:"toy"}...

View Article


error when accessing latitude and longitude value in geolib

In my react native app I have used geolib to find the nearest place to a certain point from a list of places, like thisconst nearestPlace = geolib.findNearest({ latitude:6.4423456, longitude:75.9095818...

View Article

Why is the type of ref not recognized in the child component?

I'm passing a component in a ScrollView and there I pass the ref too.const GameMulti: FC<GameMultiProps> = ({ navigation }) => { const scrollViewRef = useRef<ScrollView &...

View Article


Could not find a declaration file for module 'react-native-foo-package'

while I added any component to my pure react-native project, the application screen turns to the white empty page.The import 'react-native-foo-package' line has '...' near the package name, and it has...

View Article

Metro Builder: SyntaxError: Unexpected token = after upgrading to React...

Today I updated to React Native Version 0.65.1.After that I was unable to Start the Metro ServerI am now receiving following error message while building a Release .apk:...

View Article


Hide picked items in a FlatList

I'm using react-native FlatList to render out a punch on elements the data of which comes from an external API.I want to prevent the user from picking the same item twice. So the way I'm going about...

View Article

React Hooks: How can I use multiple instances of my useToggle hook on one...

Overview:I've created a custom useToggle react hook and I want to use two instances in one component. A toggle for the "Privacy Policy" and a toggle for the "Terms and Conditions."QuestionHow can I use...

View Article

Image may be NSFW.
Clik here to view.

React Native Navigation - Nested Navigator with Overlay

I'm having a bit of a rough time figuring out how to structure my project. I have this MiniPlayer (see 2. pic) that I would like to overlay over all other screens whenever a song is playing. So far I...

View Article
Browsing all 6366 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>