【发布时间】:2014-09-23 17:55:00
【问题描述】:
我想将我的 Nodejs 服务器上的 PouchDb 与前端的 IndexedDb 同步()。
但是:我不使用 Couch 或 Pouchdb-server
在后端我正在运行:
var pouch = require('pouchdb')
var db = new pouch('fuu');
test.app.use('/sync'),function(req,res,next){console.log('Woop woop');
db.info(function)(err,info) {return res.send('info')})
});
// same problem with : db.allDocs(..);
在前端:
var db = new PouchDB('ba');
var remoteCouch = ("http://localhost:3000/sync")
var sync = function() {
var opts = {live: true};
db.sync(remoteCouch, opts);}
sync();
但现在控制台中无休止地调用“Woob woob”,没有任何同步的..
有人知道我做错了什么吗?
【问题讨论】: