3

GitHub - kkuchta/tabdb: Using browser tabs as a database like only a maniac woul...

 10 months ago
source link: https://github.com/kkuchta/tabdb
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

TabDB

If you feel like you use your browser tabs as a database, why not make it official?

demo gif

This is an in-browser database that uses tab titles for storage.

Every time you run an SQL query, it grabs all the data stored in the neighboring tabs' titles, concatenates it, unzips it, and loads it into an in-memory sqlite database. It then runs the command, dumps the db state to a string, zips it up, and spreads it out across the available tabs.

Play with it live at tabdb.io.

comic about bad ideas

The code is awful- I hacked together the first version (which was ugly enough), then glued it onto typescript + react for fun. I didn't go so far as to properly integrate the raw JS logic with react (eg via redux or something), so it's a mishmash of global variables, commented-out code, and TODO comments. If this were production code, I'd deserve to be tarred and feathered. Since it's just a silly one-off thing, I hope you won't judge it too harshly.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK