1.0.4 • Published 4 years ago
zlitedb v1.0.4
ZLiteDB
How to add package
const ZLiteDB = require('zlitedb')
Usages
//Adding a key:
ZLiteDB.add('key', 'value')
//Setting a key:
ZLiteDB.set('key', 'value')
//Checking if the database has a key:
ZLiteDB.has('key')
//Getting a key:
ZLiteDB.get('key').then(value => {})
//Deleting a key:
ZLiteDB.delete('key')
//List all keys:
ZLiteDB.listAll().then(results => {})
//Find all keys that have a specified string included:
ZLiteDB.matchIncludes('string').then(results => {})
//Find all keys that start with a specified string:
ZLiteDB.matchPrefix('string').then(results => {})
//Find all keys that end with a specified string:
ZLiteDB.matchSuffix('string').then(results => {})
//Delete all keys
ZLiteDB.deleteAll()
//Delete all keys that has a specified string included:
ZLiteDB.deleteMatchIncludes('string')
//Delete all keys that start with a specified string:
ZLiteDB.deleteMatchPrefix('string')
//Delete all keys that end with a specified string:
ZLiteDB.deleteMatchSuffix('string')