February 8, 2008
CSS Behaviors vs CSS Expressions
In follow-up to my previous post, one thing that is worth mentioning is behaviors should always be preferred over expressions. Why? Expressions are constantly re-evaluated making slow Internet Explorer even slower.
For example, an expression doing a faux "max-width" would be recalculated hundreds of times when the mouse moves, even though the result would always be the same. The advantage of behaviours is that you can bind them to specific events, page load, window resize, etc, and in doing so reduce cpu load and improve the performance of your site.
Posted by Matt at February 8, 2008 1:29 PM
Fraggle Chitter Chatter
Have Your Say
The Great Hall
Historial Postcards
- February 2008
- January 2008
- December 2007
- November 2007
- October 2007
- September 2007
- August 2007
- July 2007
- June 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
- November 2006
- October 2006
- September 2006
- August 2006
- July 2006
- June 2006
- May 2006
- February 2006
- January 2006
- December 2005
- November 2005
- October 2005
- September 2005
- August 2005
- July 2005
- June 2005
- May 2005
- April 2005
- March 2005
- February 2005
Ask Marjorie