Skip to content

Commit

Permalink
print out errors in the browser
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Oct 8, 2014
1 parent 34acf93 commit afc61e8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions bin/cmd.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ function bundle () {
var wb = w.bundle();
wb.on('error', function (err) {
console.error(String(err));
fs.writeFile(outfile, 'console.error('+JSON.stringify(String(err))+')', function(err) {
if (err) console.error(err);
})
});
wb.pipe(fs.createWriteStream(dotfile));

Expand Down

0 comments on commit afc61e8

Please sign in to comment.