8 ms·
> What I miss from it that SQLite doesn’t provide is the ability to run it on the browser. Cries in abandoned Web SQL[0] [0] https://en.m.wikipedia.org/wiki/W
by virtualwhys 6y ago
> What I miss from it that SQLite doesn’t provide is the ability to run it on the browser.
Cries in abandoned Web SQL[0]
[0] https://en.m.wikipedia.org/wiki/Web_SQL_Database https://en.m.wikipedia.org/wiki/Web_SQL_Database
- CodesInChaos 6y agoIMO compiling sqlite to webassembly is a better approach than declaring a specific implementation a standard and integrating it in browsers.
- majewsky 6y agoHaving it on the browser level would have the huge advantage of the DB contents being visible to the users in devtools (not just to the developers via their custom tooling).
- osmarks 6y agoI don't think browsers have a good API it could store to, though. As far as I know there isn't really anything for storing efficiently in-place updateable/readable large binary blobs.
- CodesInChaos 6y agoWhat about IndexedDB? A basic implementation would use one document per page. An advanced integration might replace the whole sqlite storage engine with one based on IndexedDB.
- osmarks 6y agoThat could work, I forgot SQLite worked by pages. It's still probably not ideal, though.
- zubairq 6y agoYeah, I agree. At AppShare we take our server side databases and let them run in the browser. We even copy the data so that you can take a server side Sqlite database as save the Sqlite engine and all the data as a HTML file
- MaxBarraclough 6y agoWhat do you make of IndexedDB?
- virtualwhys 6y agoI'd like to make it go away, but as a simple k-> v store it's decent enough. Web SQL provided relational data and aggregation, something that's sorely lacking from IndexedDB (and the libraries that build on top of it, poorly replicating SQL in the browser). The amount of client side code one has to write to replicate simple SQL group by/sum operations is mind numbingly bad -- not to mention performance hit vs. SQLite's blazing native C performance (and it shipped with the browser to boot, no separate download of some lousy bloated 3rd party JS library).