feat: 屏蔽MC中无用的类库
This commit is contained in:
parent
e93a438cc2
commit
7754f7f83b
@ -4,11 +4,11 @@
|
|||||||
|
|
||||||
var NodeBuffer;
|
var NodeBuffer;
|
||||||
|
|
||||||
try {
|
// try {
|
||||||
// A trick for browserified version, to not include `Buffer` shim
|
// // A trick for browserified version, to not include `Buffer` shim
|
||||||
var _require = require;
|
// var _require = require;
|
||||||
NodeBuffer = _require('buffer').Buffer;
|
// NodeBuffer = _require('buffer').Buffer;
|
||||||
} catch (__) {}
|
// } catch (__) {}
|
||||||
|
|
||||||
var Type = require('../type');
|
var Type = require('../type');
|
||||||
|
|
||||||
|
@ -9,14 +9,14 @@ var esprima;
|
|||||||
// If not found - try to fallback to window.esprima. If not
|
// If not found - try to fallback to window.esprima. If not
|
||||||
// found too - then fail to parse.
|
// found too - then fail to parse.
|
||||||
//
|
//
|
||||||
try {
|
// try {
|
||||||
// workaround to exclude package from browserify list.
|
// // workaround to exclude package from browserify list.
|
||||||
var _require = require;
|
// var _require = require;
|
||||||
esprima = _require('esprima');
|
// esprima = _require('esprima');
|
||||||
} catch (_) {
|
// } catch (_) {
|
||||||
/*global window */
|
// /*global window */
|
||||||
if (typeof window !== 'undefined') esprima = window.esprima;
|
// if (typeof window !== 'undefined') esprima = window.esprima;
|
||||||
}
|
// }
|
||||||
|
|
||||||
var Type = require('../../type');
|
var Type = require('../../type');
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user