59,994 Installs and Counting! Get Sparks Now!
Hey! Keep up to date with the project through its beta and public launch by following @getsparks.
Tweet
The Top Sparks of 2011
December 31, 2011
from: codefury.net
CodeIgniter Starter Project − A Starting Point for Any CI Dev
December 12, 2011
from: github.com
NetTuts+ Tutorial for GetSparks
November 24, 2011
from: net.tutsplus.com
Simple Assets Library (minify, combine, LESS)
| Contributor | : bstrahija |
| : Log in to view | |
| Author Website | : http://creolab.hr |
| Spark Website | : https://github.com/bstrahija/assets |
| Repository Type | : git |
| Number of Installs | : 796 |
php tools/spark install -v0.6.3 assets
Or download this version manually:
Get assets-0.6.3.zip
A simple assets library that has the ability to combine and minify your JavaScript and CSS assets. Additionally there's a LessPHP compiler, based on the original Ruby implementation.
The libraries JSMin, CSSMin and LessPHP are all created by third parties, but they're included in this package for convinience.
Set all your preferences in the config file (assets directories, options to minify, combine and parse with LessPHP). Now you can use the helper methods in your views like this:
<?php display_css(array('init.css', 'style.css')); ?>
<?php display_js(array('libs/modernizr-1.6.js', 'libs/jquery-1.4.4.js', 'plugins.js', 'script.js')); ?>
There's also a method for clearing all cached files:
$this->assets->clear_cache();
The default configuration assumes your assets directory is in the root of your project. Be sure to set the permissions for the cache directory so it can be writeable.
/application
/assets
/cache
/css
/images
/js
/sparks
/system
php tools/spark install -v0.6.2 assets
Or download this version manually:
Get assets-0.6.2.zip