es3ify
Advanced tools
Comparing version 0.1.3 to 0.1.4
12
index.js
@@ -111,2 +111,3 @@ var Syntax = require('esprima-fb').Syntax; | ||
function process(file) { | ||
if (/\.json$/.test(file)) return through(); | ||
var data = ''; | ||
@@ -118,3 +119,12 @@ function write(chunk) { | ||
function compile() { | ||
this.queue(transform(data)); | ||
var source; | ||
try { | ||
source = transform(data); | ||
} catch (e) { | ||
return this.emit('error', e); | ||
} | ||
this.queue(source); | ||
this.queue(null); | ||
@@ -121,0 +131,0 @@ } |
{ | ||
"name": "es3ify", | ||
"version": "0.1.3", | ||
"version": "0.1.4", | ||
"description": "Browserify transform to convert ES5 syntax to be ES3-compatible.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
7672
150