Open jordan-vdi opened 5 months ago
I found this comment while digging through some issues on the yarn repo.
https://github.com/yarnpkg/yarn/issues/5347#issuecomment-463038189
It seems this is a common practice. The recommendation would be to switch the two dependencies from peer dependencies to actual dependencies. This would ensure that these dependencies are installed when running yarn
.
I made the in my local project and the errors went away.
I'm curious if you were doing anything else to deal with these errors.
I've added them as peerDependencies
, because both react-native-reanimated
and react-native-gesture-handler
require additional setup for them to work properly on all platforms.
In the README
of this repository I've mentioned that before installing react-native-pan-pinch-view
you need to have those two packages installed & setup. I've also specified versions of said packages, because they tend to introduce breaking changes freqently.
@fakeheal Yup, and that works in the project that I am using this in. I see that the peerDependencies
should stay.
The issue that I am running into is when I tried to add the feature mentioned in #10. In a development context the two dependencies need to be present in order to pass the yarn typecheck
which is a contribution requirement.
It looks like you accounted for this by using install-peers
, but that didn't work for me. It might be related to this. https://github.com/alexindigo/install-peers/issues/8
Oh, I see, sorry I kind of misunderstood your first comment.
I will have to delve deeper into the install-peers
and how to handle peerDependencies
in npm packages with demos.
I am trying to get this project running locally so I can attempt some pull requests, but I am running into a consistent typescript error after installing.
After installing and running
yarn typecheck
I receive these errors.I'll continue to investigate, I figured it was worth mentioning here for visibility.