From 0191a1556c33e0814ffbddd29c6ecbc0ffea60da Mon Sep 17 00:00:00 2001 From: Tyler Kellen Date: Tue, 11 Sep 2012 06:56:17 -0500 Subject: [PATCH] partially revert e8c7b37 --- package.json | 4 ++-- tasks/jst.js | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index db8b5fd..cc9b6bb 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "grunt-contrib-jst", "description": "Precompile Handlebars templates to JST file.", - "version": "0.2.0", + "version": "0.2.1", "homepage": "https://github.com/gruntjs/grunt-contrib-jst", "author": { "name": "Tim Branyen", @@ -38,4 +38,4 @@ "keywords": [ "gruntplugin" ] -} \ No newline at end of file +} diff --git a/tasks/jst.js b/tasks/jst.js index fb48f55..01c53c1 100644 --- a/tasks/jst.js +++ b/tasks/jst.js @@ -10,6 +10,8 @@ module.exports = function(grunt) { "use strict"; + var _ = require("underscore"); + var jst = function(source, filepath, namespace, templateSettings) { try { return namespace + "['" + filepath + "'] = " + _.template(source, false, templateSettings).source + ";"; @@ -21,7 +23,6 @@ module.exports = function(grunt) { grunt.registerMultiTask("jst", "Compile underscore templates to JST file", function() { - var _ = require("underscore"); var helpers = require("grunt-contrib-lib").init(grunt); var options = helpers.options(this, {namespace: "JST", templateSettings: {}});