/ui-local-db

:tophat: A scalable and flexible Javascript tool to work with localStorage. :briefcase: In this way uses a special abstraction level - DataBase functionality, which exposes the main methods for data managing.

Primary LanguageJavaScript

ui-local-db

Database implementation within user's browser environment.

What is it for

This module is an implementation to store data on the user's device within him work through Web. Actually, it has CRUD behaviour to work with data (create, read, update, delete).

How to use

var dbPanel = new dBControl();

This action initializes control to work with data within current user session.

dbPanel.create('First');

Create a new data store in the localStorage. This action is required and have to be involved necessarily to use almost all control methods.

dbPanel.connect('First');

Call specified localDB to work.

dbPanel.clear();

Reset all data for the current localDB. Furthermore, the connection with current localDB wont be lost.

dbPanel.disconnect();

Disconnect and back to the main control state.

dbPanel.drop('Title');

Remove localDB from the common storage by the received title.

dbPanel.displayMessages(bool);

Show\ignore specific infrom messages into browser console.

dbPanel.find('Some title');

Find localDB at the common storage.

dbPanel.getAll();

Find and return collection of exist localDB's in the user localStorage.

dbPanel.getData();

Retrieve data inside current localDB.

dbPanel.getInfo();

Display common info about current localDB.

dbPanel.removeValue('Some');

Delete the property from the current localDB.

dbPanel.setValue('Another');

Set a new value into the current localDB.