Skip to content

Commit

Permalink
stupid markdown parens
Browse files Browse the repository at this point in the history
  • Loading branch information
James Halliday committed Aug 27, 2010
1 parent a56b629 commit 0bd932b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -126,5 +126,5 @@ Hash supports map(), filter(), and reduce(). In the first style, you can chain
together operations before the ".end". Each callback is executed like this:
f.call(hash, value, key)

See also "creationix's pattern/hash":http://github.com/creationix/pattern, which
does a similar thing except with hash inputs and array outputs.
See also [creationix's pattern/hash](http://github.com/creationix/pattern),
which does a similar thing except with hash inputs and array outputs.
8 changes: 6 additions & 2 deletions lib/web.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,14 @@ var fs = require('fs');

// return a special webified version of traverse
exports.source = function () {
return fs.readFileSync(__dirname + '/traverse.js')
[ 'traverse.js', 'hash.js' ].map(scrub).join('\n');
};

function scrub (filename) {
return fs.readFileSync(__dirname + '/' + filename)
.toString()
.replace(/^module\..*/mg, '')
.replace(/^var \S+\s*=\s*require\(.*\);/mg, '')
;
};
}

0 comments on commit 0bd932b

Please sign in to comment.