I am getting this issue while using moti library with react native - react-native

I installed reanimated and moti library both and added reanimated plugin in babe-config-js file still getting this issue

Related

react-native-fs not working on react-native version 0.69

I am using react-native version 0.69 and I want to read a file stored in assets in my react native project.
using following syntax in App.js
import fs from 'react-native-fs';
I have installed 'react-native-fs' and followed all the links I could find on the internet but I am still getting below error while running the app.
ERROR TypeError: null is not an object (evaluating 'RNFSManager.RNFSFileTypeRegular')
ERROR Invariant Violation: "main" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current
project.
* A module failed to load due to an error and `AppRegistry.registerComponent` wasn't called.
I tried to run react-native link react-nativs-fs but link support has been removed in react-native >= 60 as mentioned in official docs,
I am unable to get this to work, any help would be appreciated. I have seen similar issues on the stackoverflow but none has given the answer for react native >=0.60 versions
Also I am using expo to create the app.
my OS is Windows 10 64 bit.
react-native-fs is not supported with Expo but it is only supported by Pure React Native.
Expo has a package that offers filesystem support:
expo-file-system

Why is React imported in a React-Native project and which versions are compatible?

I'm following the react-hook-form docs to implement the demo in my react-native project. https://react-hook-form.com/get-started/#:~:text=import-,React,-from%20%22react%22%3B%0Aimport%20%7B%20Text
I realized I must install React, so I did, but when I ran the form component, I got a Render Error "Can't find variable: React". I checked the react-native CLI and saw there was a warning about 'react-native missing peer dependency React#17.0.1'
I downgraded from react 17.0.2 but I still get this error.
So my question is, why must we import React to use libraries like react-hook-form in react-native?
And how do you tell which react version is compatible with react-native?

How to link native library to react native application and what is the folder structure?

I am trying to build simple app to creative native library and link with react native app.
I am facing issue like
Error : Unable to resolve module react-native-fingerprint from App.js: react-native-fingerprint could not be found within the project.
Note : 'react-native-fingerprint' which is been created and want to link with app.
I guess you're using react-native-fingerprint-scanner. Since library you mentioned doesn't exist.
In case if you using this library react-native-fingerprint-scanner.
Installation
npm install react-native-fingerprint-scanner --save
or
yarn add react-native-fingerprint-scanner
Link to Native Platforms
react-native link react-native-fingerprint-scanner
Even after this it is not working. Following this guide

Error with React Native 0.53RC using Expo Client version 2.3.0

I got this error that says:
React Native version mismatch.
JavaScript version 0.50.3
Native Version 0.52.0
I have used Expo Client 2.3.0 on my Android mobile device. This attached screenshot shows the error:
Regards
React Native 0.53-rc is not a version that is supported by Expo and you always need to match the versions of React Native's JS and native code.
When you specify an Expo SDK version, that tells Expo which of its included versions of React Native to run. For example, Expo SDK 25 corresponds to React Native 0.52; a project that specifies "sdkVersion": "25.0.0" would make Expo load the native code for React Native 0.52.
Important: This also means you must use the JavaScript for React Native 0.52. The most reliable way to do this is to use the corresponding copy of React Native released by Expo, which often looks like:
"react-native": "https://github.com/expo/react-native/archive/sdk-25.0.0.tar.gz"

React native source not compiling correctly when using mocha + babel

Im having a bit of an issue after upgrading to React Native 0.30. Using mocha, and babel I transpile the react native source before test run. I'm now seeing issues where modules cannot be found.
Here's an example:
Error: Cannot find module 'AssetRegistry'
The corresponding file can be found here https://github.com/facebook/react-native/blob/master/Libraries/Image/AssetSourceResolver.js#L21. It looks as if babel cannot locate the AssetRegistry file that is local in this directory.
Ok so it turns out that react-native-maps was calling an internal react-native library. react-native-mock has most of the internals mocked for react native however the internal library for the Image utility was not mocked.
I just used mockery to mock the library and all seems to work now.