Questions tagged [react-native-reanimated-v2]

242 questions
0
votes
1 answer

react-native-reanimated & react-navigation/drawer dependency error

I'm into a problem that I have already asked the discussions tab in the react-native-reanimated GitHub repository: this is the link in the github repo I have cloned a react-native project and tried to install npm packages using npm install, but I…
0
votes
0 answers

Build failed because of react native reanimated 2

I install react native reanimated 2 according to its installation doc. But when I run project for android build, I get this error: FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':app:mergeDebugNativeLibs'. >…
7th storm
  • 41
  • 1
  • 9
0
votes
1 answer

Flipper will not pause at any breakpoints - react-native - react-native-reanimated

I have recently moved to debugging with Flipper after installing react-native-reanimated, however it doesn't pause on breakpoints. I am using react-native 0.65.0 and react-native-reanimated 2.3.0-alpha.3. The log in the screenshot is in the console…
AngularBoy
  • 1,715
  • 2
  • 25
  • 35
0
votes
0 answers

How can I disable RCTView?

I'm trying to build android app with react native. I kept getting this error: ERROR Invariant Violation: requireNativeComponent: "RCTView" was not found in the UIManager. This error is located at: in RCTView (at View.js:32) in View (at…
upoque
  • 53
  • 8
0
votes
1 answer

scrollHandler and scrollTo in animated scrollview

Is there a way to use scrollHandler (for updating the shared value) and scrollTo together https://snack.expo.dev/@haniq313/scrollview-with-handler-and-scrollto Snack and code below. Problem is when i press the Next button the scrollTo works but also…
Hani Q
  • 135
  • 2
  • 15
0
votes
1 answer

How to animate multiple component opacity with react native reanimated 2?

I am learning react native reanimated. I am trying to make multiple component visible at the same time when user press a button. But when ever I press the button only the last component become visible. I am using react native reanimated2 Here is the…
Kerry
  • 384
  • 3
  • 25
0
votes
1 answer

Share animation values with child components - React reanimated 2

I have a snack here where I want to take the scroll Y value and pass it to an animated view inside a sibling component and have that view animate as I scroll, for this example I just want to animate the height. Smaller when scrolling down, larger…
wind_kind
  • 561
  • 6
  • 23
0
votes
1 answer

How to create a pinch to zoom camera app using reanimated 2 [REACT-NATIVE]

I'm trying to create a react native camera app using reanimated 2 that enable the camera zoom, here's my code: const scale = useSharedValue(1); const onGestureEvent = useAnimatedGestureHandler({ onStart: (_, ctx) => { ctx.start =…
PietroPutelli
  • 482
  • 4
  • 20
0
votes
0 answers

React-native android textInput don't respond to focus when tap on it

I'm using a textInput to search some keywords on an expo project and after a small animation, the user can write on the input ... It works perfectly on IOS but on android it responds only if I tap on the extreme right of my input. Here is my…
0
votes
1 answer

How to use useAnimatedStyle inside a FlatList renderItem?

im trying to create a carousel effect upon scrolling using renimatedV2 and im realizing that because of the useAnimatedStyle hook dependency I cannot apply the animated style over to the view. Reason is it is a hook and I cannot place it inside the…
haibert
  • 148
  • 1
  • 12
0
votes
1 answer

Pass useAnimatedGestureHandler via forwardRef

I'm about to swap the old React Native Animated library with the new React Native Reanimated one to gain performance issues but I have encountered one problem I could not solve. In all examples I found online, I saw that the GestureHandler, created…
0
votes
1 answer

How to land on the image a user has clicked in image swipe?

My React Native 0.64 app uses react-native-gesture-handler 1.16/react-native-reanimated 2.1 to swipe images left and right. The idea is when user clicks a image in image gallery, then the image was displayed occupying the full screen and the rest of…
0
votes
1 answer

convert reanimated 1 to 2

What's the equivalent of this: const scrollViewStyle = useMemo( () => [ { opacity: interpolate(animatedIndex, { inputRange: [0, 1], outputRange: [0, 1], extrapolate: Extrapolate.CLAMP, }), }, ], …
Ben
  • 2,957
  • 2
  • 27
  • 55
0
votes
1 answer

How can i change background Color with transition using reanimated v2

I new to react-native-reanimated. I'm trying to change backgorundCOlor depending on the state. For now I have such code: const [visible, setVisible] = useState(true) const backgroundColor = useSharedValue(0); const backgroundColorStyle =…
Win
  • 25
  • 1
  • 6
0
votes
3 answers

How to update shared value after async operation?

const [action, setAction] = useState(true); const sharedVal = useSharedValue(action ? 10 : 20) useEffect(() => { setTimeout(() => { setAction(false) }, 2000) }, []) In the above code, the value of shareVal doesn't change the value…
1 2 3
16
17