Skip to content

Commit

Permalink
compatibility with vuex-easy-firestore
Browse files Browse the repository at this point in the history
  • Loading branch information
mesqueeb committed Jun 28, 2018
1 parent 758233a commit a6a0087
Show file tree
Hide file tree
Showing 7 changed files with 55 additions and 19 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ The Vuex Easy Access plugin does two things:
1. Add a global getter/setter for each state property
2. Automatically generate mutations for each state property

Todo
1. Make it so it doesn't matter if the user uses `/` or `.`
<!-- Todo -->
<!-- 1. Make it so it doesn't matter if the user uses `/` or `.` -->

### Table of contents

Expand Down
56 changes: 47 additions & 9 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.min.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "vuex-easy-access",
"version": "1.0.11",
"version": "1.0.12",
"description": "Unified syntax with simple set() and get() store access + auto generate mutations",
"main": "src/index.js",
"main": "dist/index.min.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build": "npm i && npm i rollup -g && rollup -c build/rollup.js"
Expand Down
4 changes: 1 addition & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ function createEasyAccess (userConfig) {
const conf = Object.assign(defaultConfig, userConfig)
const vuexEasyFirestore = conf.vuexEasyFirestore
return store => {
store[conf.setter] = (path, payload) => {
console.log('vuexEasyFirestore → ', vuexEasyFirestore)
return defaultSetter(path, payload, store, vuexEasyFirestore) }
store[conf.setter] = (path, payload) => { return defaultSetter(path, payload, store, vuexEasyFirestore) }
store[conf.getter] = (path) => { return defaultGetter(path, store) }
}
}
Expand Down

0 comments on commit a6a0087

Please sign in to comment.