You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,42 +1,42 @@
1
1
# Async Storage
2
2
3
-
A collection of persistent data storages, unified into a single API.
3
+
A collection of persistent data storages, targeting different platforms, unified within a single API.
4
4
5
5
## Work in progress
6
6
7
7
Async Storage v2 is under development.
8
8
9
-
If you're looking for published and operational Async Storage version, please check out [`LEGACY`](https://github.com/react-native-community/async-storage/tree/LEGACY) branch.
9
+
If you're looking for published and operational Async Storage version, please check out [`LEGACY`](https://github.com/react-native-community/async-storage/tree/LEGACY) branch.
10
10
11
11
## Features
12
12
13
-
-Unified API to consume any supported storage
14
-
-Different type of storage for different purpose, see [available storages](#available-storages)
15
-
-Extensible functionality, to leverage full storage potential
Copy file name to clipboardExpand all lines: examples/mobile/README.md
+7-12Lines changed: 7 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,16 @@
1
-
# Async Storage mobile examples
1
+
# Async Storage - Mobile example
2
2
3
-
## Running the example
3
+
Example React Native app presenting features of [`async-storage-backend-legacy`](https://github.com/react-native-community/async-storage/tree/master/packages/storage-legacy).
4
4
5
-
1. Get dependencies
5
+
## Running the app
6
+
7
+
1. Install dependencies
6
8
7
9
```bash
8
10
$ yarn install
9
11
```
10
12
11
-
2.Install the app
13
+
2.Run the app on either platform
12
14
13
15
```bash
14
16
# Android
@@ -18,16 +20,9 @@ $ yarn start:android
18
20
$ yarn start:ios
19
21
```
20
22
21
-
3. Run packager
22
-
23
-
```bash
24
-
$ yarn start
25
-
```
26
-
27
23
## Feedback
28
24
29
-
Let me know about any issue found or feedback you have at [Async-Storage issue page](https://github.com/react-native-community/async-storage/issues).
30
-
Please mark it as `examples` label.
25
+
All feedback is welcome at [Async-Storage issue page](https://github.com/react-native-community/async-storage/issues).
Copy file name to clipboardExpand all lines: examples/web/README.md
+7-6Lines changed: 7 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,23 +1,24 @@
1
-
# Async Storage Web examples
1
+
# Async Storage - Web example
2
2
3
-
## Running the example
3
+
Example React app presenting features of [`async-storage-backend-web`](https://github.com/react-native-community/async-storage/tree/master/packages/storage-web).
4
4
5
-
1. Get dependencies
5
+
## Running the app
6
+
7
+
1. Install dependencies
6
8
7
9
```bash
8
10
$ yarn install
9
11
```
10
12
11
-
2. Run application
13
+
2. Run the app
12
14
13
15
```bash
14
16
$ yarn start
15
17
```
16
18
17
19
## Feedback
18
20
19
-
Let me know about any issue found or feedback you have at [Async-Storage issue page](https://github.com/react-native-community/async-storage/issues).
20
-
Please mark it as `examples` label.
21
+
All feedback is welcome at [Async-Storage issue page](https://github.com/react-native-community/async-storage/issues).
Copy file name to clipboardExpand all lines: packages/core/docs/Writing_Storage_Backend.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Authoring Storage Backend
2
2
3
-
Async Storage is a [facade](https://en.wikipedia.org/wiki/Facade_pattern) over the underlying Storage solution.
3
+
Async Storage is a [facade](https://en.wikipedia.org/wiki/Facade_pattern) over the underlying Storage solution.
4
4
In order for the new storage to be compatible, it has to implement `IStorageBackend` and its methods.
5
5
6
6
@@ -22,8 +22,8 @@ that simplifies access to the storage features. Those methods are:
22
22
-`removeSingle` - removes an entry for provided `key`
23
23
-`getMany` - returns an array of `values`, for a provided array of `keys`
24
24
-`setMany` - provided an array of `key-value` pairs, saves them to the storage
25
-
-`removeMany` - removes a bunch of values, for a provided array of `keys`
26
-
-`getKeys` - returns an array of `keys` that were used to store values
25
+
-`removeMany` - removes a bunch of values, for a provided array of `keys`
26
+
-`getKeys` - returns an array of `keys` that were used to store values
27
27
-`dropStorage` - purges the storage
28
28
29
29
@@ -34,7 +34,7 @@ Few points to keep in mind while developing new storage:
34
34
35
35
36
36
37
-
## Going being default API
37
+
## Going beyond the default API
38
38
39
39
Unified API can be limiting - storages differ from each other and contain features that others do not. Async Storage comes with an extension property, that lets you extend its standard API.
40
40
@@ -86,13 +86,13 @@ async function removeOldEntries() {
86
86
87
87
## Example
88
88
89
-
Let's create a storage backend for web, using `LocalStorage` API.
89
+
Let's create a storage backend for web, using `LocalStorage` API.
90
90
91
91
Start by adding `AsyncStorage` to your dependencies.
92
92
93
93
```bash
94
94
$ yarn add @react-native-community/async-storage
95
-
```
95
+
```
96
96
97
97
Then, create a class and implement `IStorageBackend` interface;
Copy file name to clipboardExpand all lines: packages/storage-legacy/README.md
+9-3Lines changed: 9 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,16 @@
1
1
# Storage Backend: Legacy
2
2
3
-
An `AsyncStorage` storage backend, fully compatible with former version.
3
+
Storage backend for `Async Storage`, targeting Mobile platform (React-Native). Compatible with [former version of `Async Storage`](https://github.com/react-native-community/async-storage/tree/LEGACY/).
0 commit comments