I want to move images inside the view but the images should not go beyond the boundaries of the view(screen)
like that:
https://snack.expo.dev/@aisylu24/draggable-image-within-parent-boundaries-
click to see screenshot - i want to move only inside gray view
but I need to use Animated or Reanimated with gesture-handler and Functional component
Maybe I need to use layout for view but I don't know how to do it?
this is my snack where I need to do like that:
https://snack.expo.dev/@aisylu24/lookbook
Click on one of the pictures to see it
You can use a React-native gesture handler for capturing events.
https://docs.swmansion.com/react-native-gesture-handler/docs/gesture-handlers/api/pan-gh/
For animated value you can use default
Animatedfrom react-nativeand for boundary fixing, you need to learn the concept of interpolation,
instead of
[0,100]you need to add a range based on the area you want.