Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

[v4] Should react-native-reanimated be an optional peer dependency? #889

Closed
jgornick opened this issue Apr 23, 2024 · 3 comments
Closed

Comments

@jgornick
Copy link

If I never use the animated classes, I won't need react-native-reanimated to be available and built in my native app. However, I will continuously get unmeet peer dependency warnings until I add it, which means it'll autolinked and built with my app.

I noticed that it used to be an optional peer dependency, but is now required.

How is react-native-reanimated different than react-native-svg and react-native-safe-area-context, which are optional?

Thanks!

@jgornick
Copy link
Author

Related to react-native-reanimated, does it need to be tightly coupled to version >=3.6.2? According to the docs, the APIs should be the same between 2.x and 3.x.

In order to provide greater adoption, does it make sense to open it up a bit?

@derek-primumco
Copy link

In my opinion, if someone is bothering to use Nativewind 4, especially in its current pre-release state, then they should definitely be on @latest for React Native Reanimated.

@jgornick
Copy link
Author

I tend to agree with you, but when working on a production app used by many distributed component teams, it's not as easy as seems to just force latest.

If the API and features of a 3rd party module are the same across many versions (even majors like react-native-reanimated), a library consuming that module should support the minimum version via peer deps. This helps greatly with adoption of the library too.

But this thread is more about react-native-reanimated being a peer dependency, regardless of version 😄

@nativewind nativewind locked and limited conversation to collaborators May 30, 2024
@danstepanov danstepanov converted this issue into discussion #929 May 30, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants