It is very common for an application to interact with local files. For example, a general workflow is opening a file, making some changes, and saving the file. For web apps, this might be hard to implement. It is possible to simulate the file operations using IndexedDB API, an HTML input element with “file” type, an HTML anchor element with the download attribute, etc, but that would require good
This is an absurd project. It implements a backend for sql.js (sqlite3 compiled for the web) that treats IndexedDB like a disk and stores data in blocks there. That means your sqlite3 database is persisted. And not in the terrible way of reading and writing the whole image at once -- it reads and writes your db in small chunks. It basically stores a whole database into another database. Which is a
厳密に言うと違う部分もありますが、こんなイメージだとざっくりと理解しておいてください。 DBへの接続 ではここから実際のコードを使って説明していきます。 まず、2011年4月のWDの仕様(以前の仕様)でDBへ接続するには次のように書きます。 //Chrome16, Chrome18(canary), Firefox 8 で動作します var dbName = 'mzsmTest'; //データベース名 var idb; var dbConnect = indexedDB.open(dbName); console.log(dbConnect); //-> {IDBRequest} dbConnect.onsuccess = function(e){ idb = e.target.result; //IDBDatabaseオブジェクト console.log('DB接続完了'); }; db
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く