templatifying the HTML representations in TiddlySpace

6 views
Skip to first unread message

chris...@gmail.com

unread,
May 3, 2011, 12:59:25 PM5/3/11
to tidd...@googlegroups.com

In TiddyWeb (and thus TiddySpace) the default output you get when
going to

* /bags
* /recipes
* /bags/{bag_name}
* /recipes/{recipe_name}
* /bags/{bag_name}/tiddlers
* /recipes/{recipe_name}/tiddlers
* /bags/{bag_name}/tiddlers/{tiddler_title}
* /recipes/{recipe_name}/tiddlers/{tiddler_title}

are the HTML representations of those resources. These are generated
by what's called the HTML serialization. That generates the HTML in
code.

I've started some work for TiddlySpace that generates the output using
Jinja[1] templates. This enables more robust and flexible HTML that is
easier to maintain and change. It also gets the jinja templating
system into TiddlySpace which will provide options for interesting
HTML-based interfaces in the future.

I'm hesitant, however, to merge up these changes and deploy them
without getting some feedback from the community. My latest commit
message:

https://github.com/TiddlySpace/tiddlyspace/commit/a211d434b8f3e1744907fd5ce9aa2df140162331

contains most of the questions and concerns that probably need some
attention.

Feedback desired and most welcome.

[1] http://jinja.pocoo.org/
--
Chris Dent http://burningchrome.com/
[...]

FND

unread,
May 3, 2011, 2:03:26 PM5/3/11
to tidd...@googlegroups.com
> I've started some work for TiddlySpace that generates the output using
> Jinja[1] templates. This enables more robust and flexible HTML that is
> easier to maintain and change.
> [...]

> I'm hesitant, however, to merge up these changes and deploy them
> without getting some feedback from the community.

Excellent! I remember early on (years ago now!) there were concerns
regarding excessive dependencies and avoiding framework-iness - but I
suppose those are largely invalid these days.
So I'm all for this.

(Not that it's really relevant here, but I remember starting an HTML5
serializer, never bothering to finish it because I got bored with the
overhead.)

OT:
I'm very much looking forward to a modern canonical HTML representation
for tiddlers emerging as a result of this effort, and I'd be happy to
participate in the discussion. I imagine having a solid HTML foundation
would also enable a progressive enhancement-style approach to presenting
tiddlers on the web.


-- F.

colmjude

unread,
May 10, 2011, 6:05:13 AM5/10/11
to TiddlyWeb

>
> https://github.com/TiddlySpace/tiddlyspace/commit/a211d434b8f3e174490...
>
> contains most of the questions and concerns that probably need some
> attention.
>
>> * There are (as yet) no hooks for allowing someone to declare that
>> they want to use their own template instead of the provided one
>> (presumably from a tiddler). a) I didn't want to go there yet b)
>> it's not clear what the mechanism would be (presumably something like
>> Jon's plugin) c) If we make good liquid templates we may wish to
>> only allow different CSS.

Originally I thought it would be pretty cool to be able to make my own
templates but now I think it would be better for tiddlyspace the
service and the promoter of tiddlers to define the template.
Tiddlyspace should have some sort of consistency when it comes to
displaying things, especially when displaying tiddlers.

If the default template doesn't serve someone's needs it is likely
that that need is an edge case, and it isn't feasible for users to
expect their every whim to be satisfied by tiddlyspace through
customisations and configurations.
Plus tiddlyspace has a perfectly adequate api that users can always
use to build their own alternative that meets their specific need. We
want tiddlers to be spread wide on the internet but that will never
happen if there is no need to break out of the constraints of
tiddlyspace.

Plus having the ability to define your own templates would just be
another thing that users have to get their heads around.

Having the ability to define their own CSS should be a powerful enough
approach imo.

Colm

Jeremy Ruston

unread,
May 10, 2011, 6:23:36 AM5/10/11
to tidd...@googlegroups.com
I think that the most significant impact of letting people define
their own HTML tiddler templates is that it makes it harder for us to
roll out improvements that require different tiddler HTML.

That doesn't preclude having provisions within the default template
that allow its appearance to be customised by end users more
indirectly. For instance, one could imagine a feature whereby a custom
user content copyright notice is automatically included in the footer
of each tiddler.

Cheers

Jeremy

> --
> You received this message because you are subscribed to the Google Groups "TiddlyWeb" group.
> To post to this group, send email to tidd...@googlegroups.com.
> To unsubscribe from this group, send email to tiddlyweb+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/tiddlyweb?hl=en.
>
>

--
Jeremy Ruston
mailto:jer...@osmosoft.com
http://www.tiddlywiki.com

Reply all
Reply to author
Forward
0 new messages