Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cawfree/react-native-basement
ππ§β±οΈπ¦Cache all kinds of remote dependencies.
https://github.com/cawfree/react-native-basement
cache memory persistent react react-native storage
Last synced: 13 days ago
JSON representation
ππ§β±οΈπ¦Cache all kinds of remote dependencies.
- Host: GitHub
- URL: https://github.com/cawfree/react-native-basement
- Owner: cawfree
- License: mit
- Created: 2020-05-26T21:55:53.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T07:11:03.000Z (almost 2 years ago)
- Last Synced: 2024-10-05T17:04:17.990Z (about 1 month ago)
- Topics: cache, memory, persistent, react, react-native, storage
- Language: JavaScript
- Homepage:
- Size: 1.09 MB
- Stars: 35
- Watchers: 4
- Forks: 1
- Open Issues: 31
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# π¦ react-native-basement
[**React Native Basement**](https://github.com/cawfree/react-native-basement) defines a way to easily cache remote dependencies, whether they're images, JSON or raw file content. Using the [`useBasement`](https://github.com/cawfree/react-native-basement/blob/161ac2ee4beee0ac66edb9fc0c54836e16ccbb2a/src/index.js#L54) hook, extensible declarative resource caching is a breeze. π
Caching support is a little _patchy_ in React Native. For example, there's [**iOS-only support for the Image component**](https://reactnative.dev/docs/images#cache-control-ios-only), or dedicated libraries for specific kinds of content.
If you're only interested in caching images, I'd suggest taking a look at [**react-native-cached-image**](https://github.com/kfiroo/react-native-cached-image). If you're interested in caching anything else, such as [**SVG**](https://github.com/react-native-community/react-native-svg)s or [**Lottie Animations**](https://github.com/react-native-community/lottie-react-native), then this project is your friend! (Yes, it does images too, just not as optimally by comparison!)
## π installing
```bash
yarn add react-native-basement # or npm i -s react-native-basement
```That's about it! Please check out the [**Getting Started**](./docs/GETTING-STARTED.md) guide for integration details. There's also an included [**Example App**](./example/App.js).
## βοΈ licence
[**MIT**](./LICENSE.md)