[Seaside] Dynamic CSS
Squeaker
squeakman at gmail.com
Thu Dec 4 21:28:18 UTC 2008
Greetings,
My application has a number of components subclassed from
WAComponent,e.g., VeHeader, VeFooter, VeArtist, VeArtifact etc.
The html pages that I dynamically produce can contain any subset of my
"VeComponents" (the things I subclassed from WAComponent). My question
concerns the creation of the css for my dynamically produced html pages.
Because I create the html page contents on the fly, I have no way of
knowing which of my VeComponents will be include on an html page. My
solution creates a style sheet that consists of the styling for ALL
possible VeComponents and its contained components. The resulting style
sheet is quite large.
Many times there is only one VeComponent on the page yet I have this
massive style sheet to handle the set of all possible VeComponents.
There has to be a better way. I was using the #style method for each
of my VeComponents but I have learned from this forum that this is not a
good solution and performance will not be good.
I think this all boils down to one question: Is there a way to generate
a dynamic css that would not degrade performance?
Thanks,
Frank
More information about the seaside
mailing list