Published by Mijingo

movie icon image

EE Insider Blog

Spend your time learning and developing sites with ExpressionEngine and we'll use this blog to keep you informed of all the news related to ExpressionEngine and CodeIgniter.

» Read more in the Archives.

» Have a tip? Send us your EE news.

Learn ExpressionEngine Today

Over a series of 8 videos, watch and learn as Ryan builds an entire ExpressionEngine website from beginning to end. Get started now.

Streamlined Asset Serving

Aaron Gustafson of Easy! Designs posted how they handle serving up multiple asset files (CSS, javascript) in the most efficient way possible. They are particular about organizing their CSS and javascript into multiple templates but serving that up as a dozen individual files isn’t very efficient.

A while back, it was not uncommon for us to include each of these assets into the document separately, but, as website optimization and performance folks will tell you, all of that separation leads to a lot of additional overhead because the browser must request each of those files individually. In the interest of streamlining the download process, we decided to merge all of the stylesheets together at the template level before sending them over the wire.

I keep all of the assets of sites I build outside of EE templates, but I really like this way of leveraging EE templates. It’s almost slick enough for me to rethink my ways.

Read the whole article: Template-based Asset Munging in ExpressionEngine

Posted on Jul 12, 2010 by Ryan Irelan

Filed Under: Development Tools, Site Performance

BridgingUnit01:29 on 07.13.2010

You could have the best of both worlds Ryan. Mung it all together in EE, but in that master template use PHP to include assets from outside of EE.