Skip to content

Instantly share code, notes, and snippets.

@steveruizok
Created March 17, 2022 10:59
Show Gist options
  • Save steveruizok/a366dcb365b8ad4e2a80ecddff59c390 to your computer and use it in GitHub Desktop.
Save steveruizok/a366dcb365b8ad4e2a80ecddff59c390 to your computer and use it in GitHub Desktop.
get tldraw file
var DBOpenRequest = window.indexedDB.open("keyval-store", 1);
DBOpenRequest.onsuccess = function(event) {
db = DBOpenRequest.result;
var transaction = db.transaction(["keyval"], "readwrite");
var objectStore = transaction.objectStore("keyval");
var objectStoreRequest = objectStore.get("home");
objectStoreRequest.onsuccess = function(event) {
console.log(JSON.stringify(objectStoreRequest.result))
};
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment