Skip to content
This repository has been archived by the owner on Feb 4, 2022. It is now read-only.

Commit

Permalink
Update usage example in README
Browse files Browse the repository at this point in the history
  • Loading branch information
robinvdvleuten committed Jul 19, 2021
1 parent e0bc339 commit 7d07329
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,6 @@ You can find the library on `window.createPersistedState`.

## Usage

### vuex-persistedstate 3.x (for Vuex 3 and Vue 2)

```js
import Vuex from "vuex";
import createPersistedState from "vuex-persistedstate";

const store = new Vuex.Store({
// ...
plugins: [createPersistedState()],
});
```

### vuex-persistedstate 4.x (for Vuex 4 and Vue 3)

```js
import { createStore } from "vuex";
import createPersistedState from "vuex-persistedstate";
Expand All @@ -57,6 +43,8 @@ const store = createStore({
});
```

For usage with for Vuex 3 and Vue 2, please see [3.x.x branch](https://github.com/robinvdvleuten/vuex-persistedstate/tree/3.x.x).

## Examples

Check out a basic example on [CodeSandbox](https://codesandbox.io).
Expand Down

0 comments on commit 7d07329

Please sign in to comment.