[Seaside] Re: Seaside and REST

Jason Johnson jbjohns at libsource.com
Sat Mar 31 06:04:39 UTC 2007

Andreas Raab wrote:
> BTW (and this is not a criticism of Seaside but rather the docs) there 
> is quite a bit of confusion for me about what exactly a component is 
> expected to do and what not. Like: the component shouldn't worry about 
> pages but it needs to worry about forums. Having the responsibilities 
> stated somewhere would help me getting a better feel for understanding 
> how to structure seaside apps. There are various other areas (the use 
> of styles and css, or meta tags for example) that I'm not at all sure 
> where the responsibility lies.

Well, as far as I have seen, Seaside is the best framework out there.  
But the problem I see is; due to the nature of HTML it is really hard to 
not have leaky abstractions.  The obvious example here are HTML forms.  
Normally in Seaside your component is only responsible for displaying 
itself.  It doesn't worry about things like <html>, <body> and such that 
occur in only one place.  Forms are a bit harder though since:  (1) 
every page doesn't have to have them, (2) any page can have more then 
one (afaik), and (3) the presence of form elements does not require a 
form to be present (could be JavaScript instead).

I don't personally use forms myself (the only ones I have are generated 
by Magritte), but perhaps a way to handle them is to treat the form like 
a "mini-page".  That is, the form is just one component that only has 
subcomponents.  That way the subcomponents only have to display 
themselves as usual and don't worry about the details of the form 
itself.  Then the components have the typical Seaside trait of being 
able to be arbitrarily moved around.

I don't know how other people handle it, but I know the Seashore 
components package for seaside allows nested forms, if one wanted to go 
that route.

More information about the seaside mailing list