January 4th, 2013
Decoupling presentation from content
I recently ran across theĀ anti-patternĀ of what I see as a common problem amongst designers and developers: coupled presentation and content. I’ve found that decoupling the presentation from the content makes things much easier to write, maintain and expand. Here’s a simple example: HTML <section> <div class=”margin-top-10″>Lorem Ipsum</div> </section> CSS .margin-top-10 { margin-top: 10px }; .margin-top-20 { margin-top: 20px }; (etc) …
0
04
Jan
Posted:
January 4, 2013 Friday at 2:49 am
