buhrmi / vue-pouch

Live and reactive PouchDB bindings for Vuejs
164 stars 20 forks source link

None of authentication methods not working #15

Open lukasborawski opened 7 years ago

lukasborawski commented 7 years ago

@buhrmi My plugin:

import Vue from 'vue'
import VuePouch from 'vue-pouch'
import PouchDB from 'pouchdb'
import Find from 'pouchdb-find'
import LiveFind from 'pouchdb-live-find'
import PouchdbAuthentication from 'pouchdb-authentication'

PouchDB.plugin(Find)
PouchDB.plugin(LiveFind)
PouchDB.plugin(PouchdbAuthentication)

Vue.use(VuePouch, {
  pouch: PouchDB,
  defaultDB: 'http://127.0.0.1:5984/testdb'
})

export default (ctx) => {

}

index.js:58 Uncaught TypeError: defaultDB.signup is not a function

ghost commented 6 years ago

I'm getting the exact same error... were you able to figure out what was going on? It looks like in vue-pouch/index.js that the $pouch object is attempting to call defaultDB.signup(), but defaultDB is null.

buhrmi commented 6 years ago

Hello guys, yes, the authentication functionality built into vue-pouch is very broken, not only the implementation but also the approach is wrong. I think I'm going to remove it for now.

Yoann53 commented 6 years ago

I'm getting the same error with $pouch.useAuth function. Do you plan to fix that or just remove authentication ? Uncaught TypeError: database.login is not a function at login (index.js?19c5:34) at Object.useAuth (index.js?19c5:53)

buhrmi commented 6 years ago

I think the authentication methods need a complete rewrite. Unfortunately I'm not using this library in any of my projects anymore so I'm not sure how to go about it. If somebody has an idea or wants to maintain this project let me know.

assemblethis commented 5 years ago

Is this fork the way forward?

https://github.com/MDSLKTR/pouch-vue