From b81190e1248b0bba01a3896c04b223835ba48910 Mon Sep 17 00:00:00 2001 From: deathcap Date: Sat, 9 Jan 2016 16:48:30 -0800 Subject: [PATCH] Disable unused moduleMain code for browserify compatibility The jison parser generator by default will generate a command-line interface built into the parser. node-mojangson only uses the parser object and not the command-line interface, and has no way to access it, so it can be safely disabled -- since it causes compatibility issues with some browserify transforms (and is unused), see: https://github.com/zaach/jison/issues/300 https://github.com/substack/static-eval/pull/12 --- jison_generate.js | 1 + 1 file changed, 1 insertion(+) diff --git a/jison_generate.js b/jison_generate.js index 3696a9f..6ce1412 100644 --- a/jison_generate.js +++ b/jison_generate.js @@ -5,6 +5,7 @@ var fs = require('fs'); var path = require('path'); var options = { + mainModule: function() {} }; var grammar = fs.readFileSync(path.join(__dirname, 'grammar.jison'), 'utf8');