Browse files

exports

  • Loading branch information...
1 parent 74e1344 commit 9b383f3c97d3ff5ecc8e8936743ac2945a9d3438 @tj tj committed Jul 15, 2011
Showing with 5 additions and 5 deletions.
  1. +2 −2 runtime.js
  2. +1 −1 runtime.min.js
  3. +1 −1 support/foot.js
  4. +1 −1 support/head.js
View
4 runtime.js
@@ -1,5 +1,5 @@
-var jade = (function(){
+var jade = (function(exports){
/*!
* Jade - runtime
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
@@ -92,4 +92,4 @@ exports.rethrow = function rethrow(err, str, filename, lineno){
return exports;
-})();
+})({});
View
2 runtime.min.js
@@ -1 +1 @@
-var jade=function(){exports.attrs=function(obj){var buf=[],terse=obj.terse;delete obj.terse;var keys=Object.keys(obj),len=keys.length;if(len){buf.push("");for(var i=0;i<len;++i){var key=keys[i],val=obj[key];"boolean"==typeof val||null==val?val&&(terse?buf.push(key):buf.push(key+'="'+key+'"')):"class"==key&&Array.isArray(val)?buf.push(key+'="'+escape(val.join(" "))+'"'):buf.push(key+'="'+escape(val)+'"')}}return buf.join(" ")},exports.escape=function escape(html){return String(html).replace(/&(?!\w+;)/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")},exports.rethrow=function(err,str,filename,lineno){var context=3,lines=str.split("\n"),start=Math.max(lineno-context,0),end=Math.min(lines.length,lineno+context),context=lines.slice(start,end).map(function(line,i){var curr=i+start+1;return(curr==lineno?" > ":" ")+curr+"| "+line}).join("\n");err.path=filename,err.message=(filename||"Jade")+":"+lineno+"\n"+context+"\n\n"+err.message;throw err};return exports}()
+var jade=function(exports){exports.attrs=function(obj){var buf=[],terse=obj.terse;delete obj.terse;var keys=Object.keys(obj),len=keys.length;if(len){buf.push("");for(var i=0;i<len;++i){var key=keys[i],val=obj[key];"boolean"==typeof val||null==val?val&&(terse?buf.push(key):buf.push(key+'="'+key+'"')):"class"==key&&Array.isArray(val)?buf.push(key+'="'+escape(val.join(" "))+'"'):buf.push(key+'="'+escape(val)+'"')}}return buf.join(" ")},exports.escape=function escape(html){return String(html).replace(/&(?!\w+;)/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")},exports.rethrow=function(err,str,filename,lineno){var context=3,lines=str.split("\n"),start=Math.max(lineno-context,0),end=Math.min(lines.length,lineno+context),context=lines.slice(start,end).map(function(line,i){var curr=i+start+1;return(curr==lineno?" > ":" ")+curr+"| "+line}).join("\n");err.path=filename,err.message=(filename||"Jade")+":"+lineno+"\n"+context+"\n\n"+err.message;throw err};return exports}({})
View
2 support/foot.js
@@ -1,4 +1,4 @@
return exports;
-})();
+})({});
View
2 support/head.js
@@ -1,2 +1,2 @@
-var jade = (function(){
+var jade = (function(exports){

0 comments on commit 9b383f3

Please sign in to comment.