-
-
Notifications
You must be signed in to change notification settings - Fork 779
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: added Reanimated v2 support #15
feat: added Reanimated v2 support #15
Conversation
I wonder if it will drop the usage for reanimated1 or not? |
hi @sa8ab ! thanks for submitting this PR, i'll test it now |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if it will drop the usage for reanimated1 or not?
yeah, this broke usage with Reanimated v1. However here are the solution:
in constants.ts
, change the import of easing to be
const { Easing: EasingV1, EasingNode: EasingV2 } = require('react-native-reanimated')
const Easing = EasingV2 || EasingV1
in BottomSheet.tsx
const { interpolate: interpolateV1, interpolateNode: interpolateV2 } = require('react-native-reanimated')
const interpolate = interpolateV2 || interpolateV1
hi @sa8ab , would you be able to update this pr ? i could pick it up :) |
* feat: added Reanimated v2 support (#15) * Update Easing to work with reanimated 2 * compatible with reanimated 2 * chore: updated import Easing & interpolate from reanimated Co-authored-by: sa8ab <59901734+sa8ab@users.noreply.github.com>
Hey @gorhom sorry for my late delay, I'm glad it is in the new version. |
@sa8ab nah , no worries about it, thanks for the contribution :) |
This makes the library work with reanimated 2