You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to check whether DB and Collection already exists before I create them. Please advise how to achieve.
I want to check whether DB exists before I create it
const localStorageObj = new StorageDB({
storage: window.localStorage, // storage object, default is window.localStorage. If you want to store data in memory only, you can set it null
database: localStorage.getItem('appkey'), // database name, default is 'db'
primaryKey: 'id' // primary key of collection, default is '_id'
});
I want to check whether the collection is exists before create it const UsercommentsTable = localStorageObj.get('UsercommentsTable');
The text was updated successfully, but these errors were encountered:
Hi,
I want to check whether DB and Collection already exists before I create them. Please advise how to achieve.
I want to check whether DB exists before I create it
I want to check whether the collection is exists before create it
const UsercommentsTable = localStorageObj.get('UsercommentsTable');
The text was updated successfully, but these errors were encountered: