Skip to content

Commit 10d4cd7

Browse files
committed
(docs): add more links to various systems / APIs described
- MST store & snapshots as well as localStorage & AsyncStorage - more beginner friendly and easier to get to relevant info from README - for storage, only linking to localForage made it seem more important than the others - also add link to src/ directory in the under the hood as it's felt like it needs a CTA for a while - src/ link on master doesn't have a high probability of changing, so updating that shouldn't be a big concern
1 parent a7b1822 commit 10d4cd7

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,12 @@ persist('some', someStore, {
5151

5252
- arguments
5353
- **key** *string* The key of your storage engine that you want to persist to.
54-
- **store** *MST store* The store to be persisted.
54+
- **store** *[MST](https://github.com/mobxjs/mobx-state-tree) store* The store to be persisted.
5555
- **options** *object* Additional configuration options.
56-
- **storage** *[localForage](https://github.com/localForage/localForage) / AsyncStorage / localStorage*
56+
- **storage** *[localForage](https://github.com/localForage/localForage) / [AsyncStorage](https://github.com/react-native-community/async-storage) / [localStorage](https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage)*
5757
Any Storage Engine that has a Promise-style API similar to [`localForage`](https://github.com/localForage/localForage).
58-
The default is `localStorage`, which has a built-in adaptor to make it support Promises.
59-
For React Native, one may configure `AsyncStorage` instead.
58+
The default is [`localStorage`](https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage), which has a built-in adaptor to make it support Promises.
59+
For React Native, one may configure [`AsyncStorage`](https://github.com/react-native-community/async-storage) instead.
6060
<br>
6161
Any of [`redux-persist`'s Storage Engines](https://github.com/rt2zz/redux-persist#storage-engines) should also be compatible with `mst-persist`.
6262
- **jsonify** *bool* Enables serialization as JSON (default: `true`).
@@ -87,8 +87,8 @@ Can view the commit that implements it [here](https://github.com/agilgur5/react-
8787

8888
## How it works
8989

90-
Basically just a small wrapper around MST's `onSnapshot` and `applySnapshot`.
91-
The source code is currently shorter than this README, so take a look under the hood! :)
90+
Basically just a small wrapper around MST's [`onSnapshot` and `applySnapshot`](https://github.com/mobxjs/mobx-state-tree#snapshots).
91+
The source code is currently shorter than this README, so [take a look under the hood](https://github.com/agilgur5/mst-persist/tree/master/src)! :)
9292

9393
## Credits
9494

0 commit comments

Comments
 (0)