[Seaside] dynamically chosen subcomponents

Tim Rowledge tim@sumeru.stanford.edu
Tue, 04 Jun 2002 15:15:55 -0700

Avi Bryant <avi@beta4.com> is claimed by the authorities to have written:

> > template elementNamed: 'questionPane')
> > 	class: currentQuestion paneClass;
> > 	set: ...... etc
> Not so mad.  The way I will eventually probably solve this is by allowing
> something like
> (template elementNamed: 'questionPane')
>   class: [currentQuestion paneClass];
After looking at the usual bindings stuff for a few minutes I think I'd
suggest something more in line with them just for a familiarity factor;
 (template elementNamed: 'questionPane')
   setClassTo: [currentQuestion paneClass];

or even
 (template elementNamed: 'questionPane')
   setClassTo: 'currentQuestionPaneClass;

> By the way, did you look at my UntemplatedComponent example?  I'm curious
> if that way of doing things is more to your liking.
It's hard to tell without installing it and I have to be really focused
on trying to finish this damned website first.... however a quick scan
seems interesting.

Tim Rowledge, tim@sumeru.stanford.edu, http://sumeru.stanford.edu/tim
"Yummy," said Pooh, as he rotated Piglet slowly on the spit.