@live-change/db-web
Advanced tools
Comparing version 0.1.8 to 0.1.9
function createBackend(config) { | ||
if(config.backend == 'mem') { | ||
return { | ||
levelup: require('levelup'), | ||
memdown: require('memdown'), | ||
subleveldown: require('subleveldown'), | ||
encoding: require('encoding-down'), | ||
Store: require('@live-change/db-store-level'), | ||
Store: require('@live-change/db-store-rbtree'), | ||
createDb(path, options) { | ||
const db = this.levelup(this.memdown(options), options) | ||
const db = {} | ||
db.path = path | ||
@@ -22,4 +18,3 @@ return db | ||
createStore(db, name, options) { | ||
return new this.Store(this.subleveldown(db, name, | ||
{ ...options, keyEncoding: 'ascii', valueEncoding: 'json' })) | ||
return new this.Store() | ||
}, | ||
@@ -26,0 +21,0 @@ closeStore(store) { |
{ | ||
"name": "@live-change/db-web", | ||
"version": "0.1.8", | ||
"version": "0.1.9", | ||
"author": { | ||
@@ -36,8 +36,5 @@ "email": "michal@laszczewski.com", | ||
"@live-change/db-store-level": "^0.1.13", | ||
"debug": "^4.1.1", | ||
"encoding-down": "^6.3.0", | ||
"levelup": "^4.4.0", | ||
"memdown": "^5.1.0", | ||
"subleveldown": "^5.0.1" | ||
"@live-change/db-store-rbtree": "^0.1.1", | ||
"debug": "^4.1.1" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5
6907470
65399
+ Added@live-change/db-store-rbtree@0.1.2(transitive)
- Removedencoding-down@^6.3.0
- Removedlevelup@^4.4.0
- Removedmemdown@^5.1.0
- Removedsubleveldown@^5.0.1
- Removedabstract-leveldown@6.2.36.3.0(transitive)
- Removedbase64-js@1.5.1(transitive)
- Removedbuffer@5.7.1(transitive)
- Removeddeferred-leveldown@5.3.0(transitive)
- Removeddefined@0.0.0(transitive)
- Removedencoding-down@6.3.0(transitive)
- Removederrno@0.1.8(transitive)
- Removedieee754@1.2.1(transitive)
- Removedimmediate@3.2.33.3.0(transitive)
- Removedinherits@2.0.4(transitive)
- Removedlevel-codec@9.0.2(transitive)
- Removedlevel-concat-iterator@2.0.1(transitive)
- Removedlevel-errors@2.0.1(transitive)
- Removedlevel-iterator-stream@4.0.2(transitive)
- Removedlevel-option-wrap@1.1.0(transitive)
- Removedlevel-supports@1.0.1(transitive)
- Removedlevelup@4.4.0(transitive)
- Removedltgt@2.2.1(transitive)
- Removedmemdown@5.1.0(transitive)
- Removedprr@1.0.1(transitive)
- Removedreachdown@1.1.0(transitive)
- Removedreadable-stream@3.6.2(transitive)
- Removedsafe-buffer@5.2.1(transitive)
- Removedstring_decoder@1.3.0(transitive)
- Removedsubleveldown@5.0.1(transitive)
- Removedutil-deprecate@1.0.2(transitive)
- Removedxtend@4.0.2(transitive)