Monthly Archives: July 2010

You are browsing the site archives by month.

HTML5 Storage, localStorage, WebDatabase, indexedDB.

For Babelfin, a browser plugin, I have been looking for ways to elegantly store data in the browser for each of the translations of a given word or short phrase.  The goal would be to use a data pattern that was easily portable to the two most popular extensible browsers – Chrome and Firefox.  I decided to start with Chrome durring startup weekend because it has a newer extension model and has simplified a lot of how extentions work.  Firefox still uses xul which is an odd combination of XML and Javascript, where as Chrome uses native HTML and Javascript with a few additional libraries to work with.

So for Babelfin, the goal would be to list a set of phrases that one would want to learn, or that the user might enter, and then the plugin would pre-fetch the translation and store it in the language that the user wants to learn.  If the phrase list is short, using a key-value store like localStorage would make sense, as almost every browser supports it, including IE8, and even though there are small differences, the data model and pattern would still work. However for anything other than the minimal product, a larger data set will be required for more advanced users.  And as a result it would be nice to have a query-able data set.

Twice google has tried to solve this problem, once with Google Gears, and again with Web SQL Database, which works in Chrome, Opera, and Safari, but does not work in Firefox, or IE.  Microsoft and Mozilla do not want to add SQL as a language to browser side logic, and I happen to agree.

The result is IndexedDB, a javascript data storage model in the front end, however,  IndexedDB is not quite CouchDB or MongoDB, but rather a javascript level abstraction of storage data.  Several Mozilla folks seem to think that CouchDB might be built on top of it, and so there is BrowserCouch which will try to do just that.  But, where is the BrowserMongo ( Maybe we can call it Mango, as a Norwegian, told me that Mongo means retard in Norwegian, oops. )

So in any case there is still a gap for Browser Side Storage that is query-able and indexed.  I suppose something could be built on top of localStorage, but it would be a hack until the browsers fully support it.

I am trying to find out how much work it would be to put a stub wrapper on top of Webkit’s Web SQL Database layer and have it look like IndexedDB since that seems to be what Google will support eventually, once they figure out how to thread it, but it would be nice to have something now. 😉

Dinner Parties – Mad Scientist Edition

If you have ever thrown a dinner party,  you might know how much work they are, but you also know how rewarding they are as a way to share time with friends, and to eat something good.

In San Francisco, I started a new weekly dinner party at my apartment in SoMa, and ever week we try to come up with a theme.  Sometimes that theme is easy to pull off and other times it’s a bit more of a hassle than it’s worth.

This week I have been trying to pull stuff together for a mad scientist theme, and in a town like SF you would think there are ton’s of lab supply stores.  However, google has failed to easily find me any.  Instead every biotech and chemtech startup seems to appear on the list rather than cool stores like ‘American Science and Surplus’ would back in milwaukee and chicago.

So for posterity sake I thought I would pass the ball forwards and document a few sites of interest to help prepare for the next ‘Mad Scientist Themed-Dinner party’.

Links of aspiration and inspiration

Online Stores for beakers, flasks, funnels, petri dishes and test-tubes

Some Geek Chic-ery