Peter's Blog

Redefining the Impossible

TiddlyWiki


Based on comments left on this site I decided to look at TiddlyWiki, a personal Wiki system. I'm quite amazed by it as it is based on a single html file that does it all: it contains the code in javascript and also the CSS. It gives you a wiki editor plus storage for your wiki entries, all in the same file.

The entries in the Wiki are stored in 'Tiddlers', most of which are hidden when the html file is displayed. When you click on a Wikilink in the file the corresponding tiddler is displayed in the same page (not in a different page as is the case in a regular wiki). You can double-click on any open tiddler to open it in an editor. If you edit the file or add new tiddlers you can save it to your local hard disk, giving you a new version of the html file, complete with your edited tiddlers. The TiddlyWiki html file can be stored where you like, even on a USB flash key, giving you a pretty portable notebook with no software to install wherever you are using it. If you were so moved you could put the file on a web server, unmodifed, where folk could explore it wiki-fashion or download the thing to their own computer and edit it themselves. Cool. The TiddlyWiki site http://www.tiddlywiki.com, is itself a TiddlyWiki.

There are variations on the TiddlyWiki code that work with a server backend to store the tiddlers but the mainstream implementation is designed to work as a personal wiki system stored on your own computer (or flash key).

In a way the single file implementation bothers me because it means the wiki wouldn't scale very well: if I put 1000 entries in a wiki these are all embedded in one html file. This will take time to load into the computers memory where the browser will create a huge DOM model for it. FireFox is pretty memory hungry.

The ServerSide implementations that exist appear to load the tiddlers on demand so may not have this problem. However, in this case I am not sure how the search facility is implemented, whether it is delegated to a database engine. I have the code, I should look. There is a closed source Ruby-On-Rails version and in theory I could download the client side code and reverse engineer the server side code but that would be an objectionable way of doing things by my value system. I would only do that with an open-source system, maybe based on PHPTiddlyWiki creating PythonTiddlyWiki.

I think I could live with multiple TiddlyWiki files, one per subject, all bookmarked in FireFox: not such a big problem to context switch. In terms of Quick Blogging there is an ALT-J keypress that starts a new 'journal entry', leaving me to type what I want, press TAB, enter the tags, CTRL-Enter to finish. That's nice.

The way entries are stored in the html file is pretty clean: DIV's store the entries, with attributes holding the metadata: title/wikiname, modification date, modifier and tags. Easy to get the data out if need be.

I'll give it a try, see if I am still using it after a week.


Have Your Say

I welcome constructive comments or questions but I reserve the right to delete any comments that displease me.

Who are you?

(Optional) If you enter an email address here I might email you back. Your email address will not be sold to spammers or shown anywhere

What do you have to say?