o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1384182734.804956: @value"{I" class:ETI"ProcessedAsset;FI"logical_path;TI"!locomotive/ICanHandlebarz.js;FI" pathname;TI"/Users/didier/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/locomotive_cms-2.3.1/vendor/assets/javascripts/locomotive/ICanHandlebarz.js;FI"content_type;TI"application/javascript;TI" mtime;TI"2013-11-11T00:40:29+01:00;TI" length;Ti I" digest;TI"%ead5b2607f1f3893fc9ab1b09a580602;FI" source;TI" /*! ICanHandlebarz.js version 0.1 -- by @ehntoo, based on ICanHaz.js by @HenrikJoreteg More info at: http://github.com/ehntoo/ICanHandlebarz.js */ (function ($) { /*! ICanHandlebarz.js -- by @ehntoo, based on ICanHaz.js by @HenrikJoreteg */ /*global jQuery */ function ICanHandlebarz() { var self = this; self.VERSION = "0.1"; self.templates = {}; // public function for adding templates // We're enforcing uniqueness to avoid accidental template overwrites. // If you want a different template, it should have a different name. self.addTemplate = function (name, templateString) { if (self[name]) throw "Invalid name: " + name + "."; if (self.templates[name]) throw "Template \" + name + \" exists"; self.templates[name] = Handlebars.compile(templateString); self[name] = function (data, title, raw) { data = data || {}; var result = self.templates[name](data); return raw? result: $(result); }; }; // public function for adding partials self.addPartial = function (name, templateString) { if (Handlebars.partials[name]) throw "Partial \" + name + \" exists"; Handlebars.registerPartial(name, templateString); }; self.addHelper = function (name, func, args) { if (Handlebars.helpers[name]) throw "Helper \" + name + \" exists"; if (typeof func === 'function') { Handlebars.registerHelper(name, func); } else { Handlebars.registerHelper(name, new Function(args, func)); } } // grabs templates from the DOM and caches them. // Loop through and add templates. // Whitespace at beginning and end of all templates inside