sql.js is a port of SQLite to Webassembly, by compiling the SQLite C code with Emscripten. It uses a virtual database file stored in memory, and thus doesn't persist the changes made to the database.
AlaSQL.js a JavaScript SQL database that handles both traditional relational tables and nested JSON data (NoSQL).
You can export, store, and import data from localStorage, IndexedDB, or Excel.