ydn db - How to remove store from ydn.db? -


i using ydn.db local storage.

which function can used remove store using ydb.db library ?
the stores have added follows

var schema = {   stores: [{       name:'consignments',     keypath:"timestamp"     }];  var db = new ydn.db.storage('localhost', schema); 

i wish check whether store exist in localstorage , if exists delete store , if not exist add store.

if store exist or not can known after opening database. if schema not store name, exit in connected database, existing store removed.

to delete database

var db = new ydn.db.storage('localhost', schema); 

to delete above database,

ydn.db.deletedatabase(db.getname(), db.gettype()); 

if type of database not known

ydn.db.deletedatabase('localhost'); 

Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -