Sha256: 08fd66f206d164055d913b344dcfa6649f3ff70b71bbf91a6da5deeac31720cd

Contents?: true

Size: 1.76 KB

Versions: 38

Compression:

Stored size: 1.76 KB

Contents

jade=function(exports){Array.isArray||(Array.isArray=function(arr){return"[object Array]"==Object.prototype.toString.call(arr)}),Object.keys||(Object.keys=function(obj){var arr=[];for(var key in obj)obj.hasOwnProperty(key)&&arr.push(key);return arr}),exports.merge=function merge(a,b){var ac=a["class"],bc=b["class"];if(ac||bc)ac=ac||[],bc=bc||[],Array.isArray(ac)||(ac=[ac]),Array.isArray(bc)||(bc=[bc]),ac=ac.filter(nulls),bc=bc.filter(nulls),a["class"]=ac.concat(bc).join(" ");for(var key in b)key!="class"&&(a[key]=b[key]);return a};function nulls(val){return val!=null}return exports.attrs=function attrs(obj,escaped){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+'"')):0==key.indexOf("data")&&"string"!=typeof val?buf.push(key+"='"+JSON.stringify(val)+"'"):"class"==key&&Array.isArray(val)?buf.push(key+'="'+exports.escape(val.join(" "))+'"'):escaped&&escaped[key]?buf.push(key+'="'+exports.escape(val)+'"'):buf.push(key+'="'+val+'"')}}return buf.join(" ")},exports.escape=function escape(html){return String(html).replace(/&(?!(\w+|\#\d+);)/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")},exports.rethrow=function rethrow(err,filename,lineno){if(!filename)throw err;var context=3,str=require("fs").readFileSync(filename,"utf8"),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");throw err.path=filename,err.message=(filename||"Jade")+":"+lineno+"\n"+context+"\n\n"+err.message,err},exports}({});

Version data entries

38 entries across 38 versions & 2 rubygems

Version Path
stylus-source-0.49.3 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
snowball-0.1.22 node_modules/jade/runtime.min.js
stylus-source-0.42.2 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.42.1 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.42.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.41.3 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.41.2 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.41.1 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.41.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.40.3 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.40.2 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.40.1 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.40.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.39.4 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.39.3 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.39.2 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.39.1 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.39.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.38.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js
stylus-source-0.37.0 vendor/node_modules/mocha/node_modules/jade/runtime.min.js