Add caching support

This commit is contained in:
Jeremy Bush 2012-10-24 17:32:44 -05:00
parent 3b401e17e8
commit 559e60b928

View file

@ -16,7 +16,7 @@ class Kohana_Kostache {
protected $_engine;
public static function factory()
public static function factory($cache = FALSE)
{
$m = new Mustache_Engine(
array(
@ -25,6 +25,7 @@ class Kohana_Kostache {
'escape' => function($value) {
return html::chars($value);
},
'cache' => $cache ? APPPATH.'cache/mustache' : NULL,
)
);