https://github.com/james2doyle/vuex-stateful-url
StatefulURL is a Vuex plugin that can read and write the state from a query string
https://github.com/james2doyle/vuex-stateful-url
Last synced: 8 months ago
JSON representation
StatefulURL is a Vuex plugin that can read and write the state from a query string
- Host: GitHub
- URL: https://github.com/james2doyle/vuex-stateful-url
- Owner: james2doyle
- License: other
- Created: 2020-07-04T03:20:33.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2021-03-12T22:51:51.000Z (over 5 years ago)
- Last Synced: 2025-02-07T22:05:27.914Z (over 1 year ago)
- Language: JavaScript
- Size: 381 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Vuex StatefulURL
> StatefulURL is a Vuex plugin that can read and write the state from a query string
## Demo

They way it works is that it detects state changes and syncs a compressed object to a query string.
## Installation
* `npm install --save vuex-stateful-url`
```js
// es6
// import StatefulURL from 'vuex-stateful-url';
// commonjs
const StatefulURL = require('vuex-stateful-url');
export default new Vuex.Store({
// ...
plugins: [
// your other plugins...
StatefulURL()
],
// ...
});
```
## Options
* `config.key`: the query string value to sync the state. default = `"state"` *(?state=blablabla)*
## License
[LICENSE](LICENSE)