/*\ title: $:/plugins/tiddlywiki/sqlite3store/init-sqlite3.js type: application/javascript Initialise sqlite3 and then boot TiddlyWiki This file is spliced into the HTML file to be executed after the boot kernel has been loaded. \*/ (function() { // Get the main tiddler store out of the HTML file var storeEl = document.querySelector("script.tiddlywiki-tiddler-store"), tiddlerStore = JSON.parse(storeEl.textContent); // Helper to get a tiddler from the store by title function getTiddler(title) { for(var t=0; t{ // Save a reference to the sqlite3 object $tw.sqlite3 = sqlite3; var capi = $tw.sqlite3.capi, // C-style API oo = $tw.sqlite3.oo1; // High-level OO API // Boot the console $tw.sqlConsole = new $tw.SqlConsole(); // Get version numbers console.log("sqlite3 version",capi.sqlite3_libversion()); // Boot TiddlyWiki $tw.boot.boot(); }); })(); //# sourceURL=$:/plugins/tiddlywiki/sqlite3store/init-sqlite3.js