File tree Expand file tree Collapse file tree 2 files changed +26
-3
lines changed
Expand file tree Collapse file tree 2 files changed +26
-3
lines changed Original file line number Diff line number Diff line change @@ -72,14 +72,37 @@ This fast-image fork comes with a few more features:
7272- [x] Antialiasing for borderRadius on Android
7373- [x] A bit faster re-renders
7474
75- ## Usage
75+ ## Installation
7676
7777** Note: You must be using React Native 0.60.0 or higher to use the most recent version of ` react-native-fast-image ` .**
7878
7979``` bash
80- npm i @cuvent/react-native-fast-image
80+ yarn add @cuvent/react-native-fast-image
81+ // OR: npm i @cuvent/react-native-fast-image
82+ ```
83+
84+ ### Extra step for android
85+
86+ For ETag caching to work we need to persist the ETag with the urls. For that we use ObjectBox.
87+ To enable ObjectBox add the following to your ` MainApplication.java ` :
88+
89+ ``` java
90+ import com.dylanvann.fastimage.custom.persistence.ObjectBox ;
91+ // ...
92+
93+ public class MainApplication extends Application implements ReactApplication {
94+ @Override
95+ public void onCreate () {
96+ super . onCreate();
97+ ObjectBox . init(this ); // <- ⚠️ Add this
98+ }
99+
100+ // ...
101+ }
81102```
82103
104+ ## Usage
105+
83106``` jsx
84107import FastImage from ' @cuvent/react-native-fast-image'
85108
Original file line number Diff line number Diff line change 11{
22 "name" : " @cuvent/react-native-fast-image" ,
3- "version" : " 8.5.14 " ,
3+ "version" : " 8.5.15 " ,
44 "description" : " 🚩 FastImage, performant React Native image component. Cuvent fork." ,
55 "keywords" : [
66 " cache" ,
You can’t perform that action at this time.
0 commit comments