当我开始
$ gulp watch
PouchDB已在Chrome版本50.0.2661.102(64位)
中成功创建console.log(PouchDB.version);
console.log(lodash.keys(PouchDB.adapters));
new PouchDB('myname', {
'adapter': 'idb',
'revs_limit': 1,
'auto_compaction': true
});
并输出:
5.3.2
["http", "https", "idb", "websql"]
当我重新加载页面(Cmd + R)时,我收到错误适配器丢失:
5.3.2
["http", "https", "websql"]
Error: Adapter is missing
at http://localhost:9000/bower_components/pouchdb/dist/pouchdb.js:5062:19
at http://localhost:9000/bower_components/pouchdb/dist/pouchdb.js:5076:6
at new PouchDB (http://localhost:9000/bower_components/pouchdb/dist/pouchdb.js:5026:17)
at openDb (http://localhost:9000/main/services/local-db-pouch-serv.js:313:14)
at service.open (http://localhost:9000/main/services/local-db-pouch-serv.js:48:21)
at service.open (http://localhost:9000/main/services/local-db-serv.js:26:23)
at Object.localDbResolve (http://localhost:9000/main/main.js:104:22)
at Object.invoke (http://localhost:9000/bower_components/angular/angular.js:4535:17)
at proceed (http://localhost:9000/bower_components/angular-ui-router/release/angular-ui-router.js:474:42)
at invoke (http://localhost:9000/bower_components/angular-ui-router/release/angular-ui-router.js:470:26)
这是一个错误还是我错了?