On UI as Code

Wow! as the one who brought “hypertextual algebra” to the conversation, thanks for the link to Document Calculus.

As I told in my answer to @khinsen now we are going from computational notebooks made in Pharo/GToolkit (with Grafoscopio) to extensible hypermedia wikis made in Lua/YueScript (with Cardumem).

My approach to computational wiki documents this time will use logicless templating in Mustache, so I can keep separated content from programming (eventually, I have thought in using YueScript macros… but it’s just a immature idea, while logicless templating is something that has already given us practical benefits among non-programmers in our communities). YueScript as the extension/programming language for the wiki will be able to read its contents/cards and produce outputs using them and/or their contents as input, in a similar way to TiddlyWiki, but with a more parsimonious extension language (in fact, Cardumem started from imagining such language as a Lua/Fengari extension for TiddlyWiki on a discussion about Tiddlywiki’s pros/cons). For that, YueScript will interface with Lua to access Mustache templating features with a lighter user facing syntax. BTW, I have just browse quickly the document calculus, and so far I can not locate anything related with logicless templating there, maybe because such calculus accounts for how logic is added to the document instead of kept apart by convention (for example the logicless one).

Cardumem is pretty immature now, but it seems like a sound approach. For the reactive part of the document/wiki, I imagine that we will use Server Send Events, that is what is advocated in the hypermedia world for real time hypermedia apps, like Datastar does.

3 Likes