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

TSLINT Error: Property 'Component' does not exist on type 'typeof React'

I downloaded the [react-native-redux-typescript-boilerplate]: https://reactnativeseed.com/ . The project runs smoothly in an android emulator. However, there are loads of tslint errors especially in...

View Article


How to upload an image from React Native into MySQL using Adonis Js (node js...

I have used the React Native Document picker to choose the image/file but how can I upload all of the assets data (image/pdf) to cloud and get URL back to my database (mySQL). I'm using adonis Js in...

View Article


error TS2305: Module '"react"' has no exported member 'Node'

I ran the React Native project along with the official documentation and added TypeScript to the project.Many ESlint errors occurred when I was executing 'yarn tsc', for example:App.tsx:10:14 - error...

View Article

Image may be NSFW.
Clik here to view.

Can't change ref.current.props.visible in typescript

trying to change .current but i get "cannot assign to read only property 'visible' of object '#'i think changing localVarRef.current.props.visible directly is fine because useRef is MutableRefObject.i...

View Article

JSX element type 'AppRouter' does not have any construct or call signatures

I'm building a React application where there will be one master package to manage and render all components coming in from individual modules. Here's the relevant sections:===== Package A (Individual...

View Article


react-native web application is not run in the web browser

i wrote code in react-native and saved as typescript files then try to run then app in web browser but it's throwing error of (Module parse failed: Unexpected token (a:a)You may need an appropriate...

View Article

dados não estão sendo renderizados no flatlist

data is not being rendered in flatlist on first page load, can anyone help me?I have an api in php that rotates me to json that is used in my react native app, but it only brings the data with the...

View Article

Using NativeWind With React Native Paper

I use native wind and react native paper and I use typescript in my expo project.The problem is how can I add "className" and "tw" attribute to my paper views.I've already added it on my views using...

View Article


Image may be NSFW.
Clik here to view.

Get rid of error highlighting with react native app with vscode

I am very new to react native development. I decided to make an app usingnpx react-native init someappwhich did what it was supposed to. Everything is built and compiled correctly. However there is...

View Article


Image may be NSFW.
Clik here to view.

ReactNative typescript: Axios is not allowing to pass file data FormData to...

I am building a Mobile application using ReactNative and TypeScript. I am trying to upload file using Axios so that I need to make multipart/form-data request. In javascript I can pass the file data to...

View Article

JavaScript/TypeScript - Callback not removed, why?

Colleagues, I can prove with logs that removing listener in some public component does not work. First, I see the listener is still called, second, I never see second console output, which puzzles me...

View Article

Yarn 3 typescript plugin not pulling in @types for package.json dependencies

I have a react native Typescript application which i have upgraded from yarn 1 to yarn 3. I have followed the migration document on the official docs and have two issues i'm unsure on what i should do....

View Article

REACT NATIVE TypeError: undefined is not an object (evaluating...

App.js (Login)import * as React from 'react';import {useState} from 'react';import { Text, StyleSheet, KeyboardAvoidingView, ScrollView, Image,TextInput, TouchableOpacity, View } from...

View Article


Typescript type for NativeStack header nested in a DrawerNavigator

Using React Navigation 6, I'm trying to type the header option for a Stack.Screen. As it is nested in a DrawerNavigator, I can use navigation.openDrawer(), but this is not defined in the expected type...

View Article

checking @react-native-community/netinfo network connection in react native...

I have a problem with my application. I am actually doing a network connection check in the application before I can make an API call. I'm not connected to the internet but I'm getting a contrary...

View Article


how to call a navigation inside a function which is outside from class in...

function logOut(ext_id) { console.log(ext_id); navigation.replace('UserScreen'); }in this function. i want to call a navigation but it's show me an error like "Property 'navigation' doesn't exist"

View Article

Variable type not certain according to TypeScript

See the following custom hook. It simply sets a state value to true and back to false after 2 seconds.export const useDelay = () => { const [loading, setIsLoading] = useState(false); const timer =...

View Article


React Native - URL to Binary. How to send the url in binary form to backend?

I have a Request - Form Data from Network -> Payload which contains a file (binary) element.Form Data file: (binary)id: 45451683 I don't know how to send the request to the backend to upload...

View Article

How do I set my custom React component as a Type passed to the prop of...

I'm making a GenericModal component with some custom styling. I want to pass an array of my ModalText components as props to GenericModal and have it display them. I'd like to be specific that this is...

View Article

How can I exclude a library from a Jest unit test?

I've added PendoSDK to my React Native app. App is using TypeScript and React Navigation. Although the app is working, after adding PendoSDK, it is failing most of my Jest unit tests. Here is an...

View Article
Browsing all 6287 articles
Browse latest View live


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