https://github.com/schafeld/store-without-vuex
Share data across components in a reactive manner, without VueX. See CodeSandbox
https://github.com/schafeld/store-without-vuex
javascript vuejs
Last synced: 2 months ago
JSON representation
Share data across components in a reactive manner, without VueX. See CodeSandbox
- Host: GitHub
- URL: https://github.com/schafeld/store-without-vuex
- Owner: schafeld
- Created: 2019-11-01T15:31:22.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-11-05T08:06:16.000Z (over 6 years ago)
- Last Synced: 2026-03-01T22:24:32.210Z (5 months ago)
- Topics: javascript, vuejs
- Language: JavaScript
- Homepage: https://codesandbox.io/s/github/schafeld/store-without-vuex
- Size: 29.3 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Store without VueX
> You don't need VueX for a rudimentary shopping cart or to share just a single piece of data across several components. Observable to the rescue!
Simple implementation of a store without the overhead of adding VueX.
Inspired by:
https://vuedose.tips/tips/creating-a-store-without-vuex-in-vue-js-2-6 and
https://vuejs.org/v2/api/#Vue-observable
## Build Setup
``` bash
# install dependencies
npm install
# serve with hot reload at localhost:8080
npm run dev
# build for production with minification
npm run build
# build for production and view the bundle analyzer report
npm run build --report
# run unit tests
npm run unit
# run all tests
npm test
```
For a detailed explanation on how things work, check out the [guide](http://vuejs-templates.github.io/webpack/) and [docs for vue-loader](http://vuejs.github.io/vue-loader).
[](https://codesandbox.io/s/store-without-vuex-yhdlz?fontsize=14)