How to pass parameters in StyleSheet in React native with Typescript
I have just switched my Javascript react native project to a Typescript project, but when I changed it, I got a lot of errors on inserting functions in StyleSheet()Previously i used to do it like...
View ArticleHow do I test a conditionally rendered component in React Native?
I'm building a React Native app that lists live music gigs. The user can toggle between showing the current day's gigs or the current week's gigs.If the user presses the 'Gigs Today' button, the state...
View Article"void promiseExpression" in TypeScript
Looking at a React Native app in TypeScript, and there is this fragment in a screen file:export const DetailPageScreen: FC<StackScreenProps<AuthorizedNavigatorParamList, 'Details'>> =...
View ArticleInvariant Violation: requireNativeComponent: "RNSVGSvgViewAndroid" was not...
I am having a headache with the error mentioned in the title.I am using react-native-gifted-charts (https://www.npmjs.com/package/react-native-gifted-charts/v/1.0.3)The charts works perfectly in ios...
View ArticleSupabase realtime subscriptions times out
Im trying to listen to realtime changes in my react-native app from a supabase table called "profiles". Whatever i try, i can't get it to subscribe to change son the table. Even when copying the code...
View ArticleReact Native useState causes data loss when mapping for the first time. how...
const initialData = [ { id: 1, name: `${accountList?.brideName} ${accountList?.brideSurname}`, type: 'Gelin', selected: false, tlText: accountList?.brideAccount?.accountTl, euroText:...
View ArticleWhy am I getting an Error when trying to set the domain prop of VictoryAxis?
I'm getting the below error when using a VictoryAxis by itself, without any VictoryChart.<VictoryAxis dependentAxis tickFormat={(t: number) => Number.isInteger(t) ? `${Math.round(t)}` : null}...
View ArticleTypeError: Notifications.getPermissionsAsync is not a function. Expo...
I'm trying to send push notifications using expo-notifications. I'm using the example in the documentation and it works very well with javascript. When I try it in typescript it gives me the...
View ArticleJest async test fails because void Promise never resolves
I am writing tests in Jest for a react-native project, and for some unknown (to me) reason, async tests are failing due to timeout without resolution. As far as I can tell, the promises related to the...
View ArticleCannot find module '@babel/runtime/helpers/interopRequireDefault' from...
I'm trying to build a mobile application with typescript, react-native, expo and jest. When I'm trying to run tests: FAIL src/components/Button/tests/Button.test.tsx● Test suite failed to run Cannot...
View ArticleWhy the release version of my app in react native fails to open when...
Help!!! I have this problem for more than 2 days and I tried several things that I found on StackOverflow and gitHub but I can't find a solution.Hello, I have a problem installing the Release version...
View ArticleWhen i build expo apk not configured app.json and not show app icon and not...
Here is my code and try eas buildI use this commandnpx eas build -p android --profile previewI am trying to implement a deep link on Android. Please find below the SDK details.Deep linking is not...
View ArticleI'm tryng to render a "SectionList" in "React-native", but isn't working
I'm new programing specially with React Native.I tryed to create a FlatList, it worked fine, but the data was not displayed as the away i wanted, cause i needed i header to organize the data as the...
View ArticleHow to make Victory Native chart have more natural scrolling
I have a basic bar graph chart that allows panning. The only problem is there is no momentum scrolling. In other words, when you scroll and release your finger, it stops scrolling immediately, which is...
View ArticleHow to type the style property for components to accept arrays?
In React Native, view elements accept a style property that uses CSS property names in a camel cased object:const styleObj = { width: 200, marginTop: 10}Elements also accept an array of style objects...
View ArticleType 'undefined' cannot be used as an index type
I am trying to convert a function from Javascript to Typescript but I keep running into the following error:Type 'undefined' cannot be used as an index typeI understand that undefined cannot be used as...
View ArticleHow to resolve a missing library on react-native?
Image librariesImage ErrorI'm following this tutorial https://www.youtube.com/watch?v=Ov3Z3vD5zFw&t=202s to make a Chat App, i didn't change any part of the tutorial but i got this error. The only...
View ArticleNo overload matches this call error: React Native Navigation
I'm pretty new to React Native and React Native Navigation. I'm getting an error stating:"message": "No overload matches this call.\n Overload 1 of 2, '(...args: never): void', gave the following...
View ArticleExpo "Error: Your JavaScript code tried to access a native module that...
I am working on a React Native project that was roginally crated using the React Native CLI. The other team members had started working before I joined, so I'm essentially contributing to the project...
View ArticleHow to solve undefined is not a function
I'm making a ChatApp on ReactNative, on this part I'm trying to implement a SignOut function, but i don't understand what is wrong here.enter image description hereThe error is "undefined is not a...
View Article