roninoss / rn-primitives

Style-agnostic, accessible React Native components for iOS, Android, and Web
https://rnprimitives.com
MIT License
427 stars 12 forks source link

[ Tentative ] fix: shipped code content + using web components + added examples #7

Closed mrzachnugent closed 5 months ago

mrzachnugent commented 5 months ago

Platform specific web primitives

With this PR, the web now uses the web specifc components but you have to import from @rn-primitives/<primitive>/dist/<primitive>. I couldn't get it to work with @rn-primitives/<primitive> which would be the ideal case.

Reducing the content dowloaded from npm

Before, the entire content of the folder from packages was downloaded from npm. Now, it is only what is needed.

Previously:

Screenshot 2024-06-08 at 3 14 06 PM

Now:

Screenshot 2024-06-08 at 3 13 46 PM

Added example

To test the components, I add examples from react-native-reusables