Skip to content

Commit

Permalink
Use @react-native-community/async-storage
Browse files Browse the repository at this point in the history
  • Loading branch information
robertying committed May 4, 2019
1 parent a1216e2 commit b5d4ffc
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 10 deletions.
1 change: 1 addition & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ android {
}

dependencies {
implementation project(':@react-native-community_async-storage')
implementation project(':react-native-extra-dimensions-android')
implementation project(':react-native-interactable')
implementation project(':react-native-calendar-events')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import com.RNFetchBlob.RNFetchBlobPackage;
import com.facebook.react.ReactApplication;
import com.reactnativecommunity.asyncstorage.AsyncStoragePackage;
import ca.jaysoo.extradimensions.ExtraDimensionsPackage;
import com.wix.interactable.Interactable;
import com.calendarevents.CalendarEventsPackage;
Expand Down Expand Up @@ -52,6 +53,7 @@ public boolean getUseDeveloperSupport() {
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage(),
new AsyncStoragePackage(),
new ExtraDimensionsPackage(),
new Interactable(),
new CalendarEventsPackage(),
Expand Down
2 changes: 2 additions & 0 deletions android/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
apply from: '../node_modules/react-native-unimodules/gradle.groovy'
include ':@react-native-community_async-storage'
project(':@react-native-community_async-storage').projectDir = new File(rootProject.projectDir, '../node_modules/@react-native-community/async-storage/android')
include ':react-native-extra-dimensions-android'
project(':react-native-extra-dimensions-android').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-extra-dimensions-android/android')
include ':react-native-interactable'
Expand Down
2 changes: 2 additions & 0 deletions ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,6 @@ target 'learnX' do

pod 'Interactable', :path => '../node_modules/react-native-interactable'

pod 'RNCAsyncStorage', :path => '../node_modules/@react-native-community/async-storage'

end
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"postinstall": "chmod +x patch/patch.sh && patch/patch.sh"
},
"dependencies": {
"@react-native-community/async-storage": "1.3.4",
"@react-native-community/blur": "3.3.1",
"dayjs": "1.8.13",
"expo-secure-store": "4.0.0",
Expand Down
2 changes: 1 addition & 1 deletion src/redux/store.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import AsyncStorage from "@react-native-community/async-storage";
import { applyMiddleware, combineReducers, compose, createStore } from "redux";
import { PersistConfig, persistReducer, persistStore } from "redux-persist";
import createSecureStore from "redux-persist-expo-securestore";
import AsyncStorage from "redux-persist/lib/storage";
import thunk, { ThunkMiddleware } from "redux-thunk";
import authReducer from "./reducers/auth";
import { mainReducers, rootReducer } from "./reducers/root";
Expand Down
15 changes: 6 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -799,6 +799,11 @@
"@types/istanbul-lib-coverage" "^2.0.0"
"@types/yargs" "^12.0.9"

"@react-native-community/[email protected]":
version "1.3.4"
resolved "https://registry.yarnpkg.com/@react-native-community/async-storage/-/async-storage-1.3.4.tgz#5a664484d485bcbab79648e1a0ce775b90843f29"
integrity sha512-fJmzL27x0BEjhmMXPnDPnUNCZK7bph+NBVCfAz9fzHzAamaiOkdUwuL3PvE4Oj4Kw4knP8ocw5VRDGorAidZ2g==

"@react-native-community/[email protected]":
version "3.3.1"
resolved "https://registry.yarnpkg.com/@react-native-community/blur/-/blur-3.3.1.tgz#bc9ecd6d85d89739d8180138716535ac7cfa4680"
Expand Down Expand Up @@ -983,15 +988,7 @@
dependencies:
"@types/react" "*"

"@types/react@*":
version "16.8.15"
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.8.15.tgz#a76515fed5aa3e996603056f54427fec5f2a5122"
integrity sha512-dMhzw1rWK+wwJWvPp5Pk12ksSrm/z/C/+lOQbMZ7YfDQYnJ02bc0wtg4EJD9qrFhuxFrf/ywNgwTboucobJqQg==
dependencies:
"@types/prop-types" "*"
csstype "^2.2.0"

"@types/[email protected]":
"@types/react@*", "@types/[email protected]":
version "16.8.16"
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.8.16.tgz#2bf980b4fb29cceeb01b2c139b3e185e57d3e08e"
integrity sha512-A0+6kS6zwPtvubOLiCJmZ8li5bm3wKIkoKV0h3RdMDOnCj9cYkUnj3bWbE03/lcICdQmwBmUfoFiHeNhbFiyHQ==
Expand Down

0 comments on commit b5d4ffc

Please sign in to comment.