[Seaside] #render: or #call: components.

Ramon Leon ramon.leon at allresnet.com
Tue Apr 29 01:14:47 UTC 2008


> 
> I know that this is probably a very bad practice, but I have 
> initialized component, eg. a instance variable 'bodyComp'
>  
> ok, I will show some code:
>  
> RootComponent>>initilaize
>    super initialize.
>    self bodyComp: BodyComponent new.
>  
> RootComponent>>renderContentOn: html
>    "all the head stuff"
>     bodyComponent renderContentOn: html
>     "etc."
>  

Don't do that, you should render subcomponents with #render:, never call
renderContentOn: of another component.

RootComponent>>renderContentOn: html
     html render: bodyComponent

Ramon Leon
http://onsmalltalk.com



More information about the seaside mailing list