▲ | fmajid 4 days ago | |||||||
The OP does not mention that IndexedDB itself is built on top of... SQLite. Abandoning WebSQL was truly a heinous crime against the Web. | ||||||||
▲ | jitl 4 days ago | parent | next [-] | |||||||
IndexedDB is a standard and can be implemented however the user-agent sees fit. Chromium source tree has an implementation on LevelDB and an implementation on SQLite; I'm not sure how they pick the appropriate backend. Firefox and WebKit both appear to use SQLite as the backend. WebSQL was a clunky API, but not as clunky as IndexedDB which is truly yucky and very easy to get wrong in modern apps that use promises. | ||||||||
| ||||||||
▲ | dunham 4 days ago | parent | prev | next [-] | |||||||
It's leveldb with a custom key format in chrome and electron. It would be nice to have WebSQL though, even if it has to be spec'd as "it's sqlite". | ||||||||
▲ | matharmin 4 days ago | parent | prev [-] | |||||||
wa-sqlite on top of OPFS is actually pretty great these days. Performance is about half of what I'd get in native SQLite, which is not too bad overall. It's around 10x faster than SQLite on top of IndexedDB for large databases in my experience. It's much better than WebSQL could ever be. You get the full power of modern SQLite, with the version, compile options, additional extensions, all under your control. |