[Cppcms-users] combining all js and css requests in a single file
Brought to you by:
artyom-beilis
From: Aris S. <ari...@gm...> - 2010-12-16 07:19:11
|
Hi, My opinion in web development, specifically if we have many "js and css" resources, although we have high performance http server, many "js and css" requests will result poor performance (vary in case). A technique used in YUI javascript framework is with combining all request in single file. They provide, named Combo API to access YUI resources, complete with its dependency configurator. Here the example of combining 4 javascript request: <script type="text/javascript" src="http://yui.yahooapis.com/combo?2.8.2r1/build/yahoo/yahoo-min.js&2.8.2r1/build/dom/dom-min.js&2.8.2r1/build/event/event-min.js&2.8.2r1/build/element/element-min.js&2.8.2r1/build/tabview/tabview-min.js"></script> and for css: <link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/combo?2.8.2r1/build/fonts/fonts-min.css&2.8.2r1/build/tabview/assets/skins/sam/tabview.css"> Combo API is useful to minimize http request. How about added this feature (combo api) in CppCMS so we don't need combine it ourself? How about combining small images so we can access it with css sprite? -aris |