Files
Tim van der Lippe fe1b426acc Update Istanbul packages and configuration
- Update istanbul-lib-instrument (breaking change is not affecting us)
- Explicitly update @istanbuljs/schema to 0.1.3. This directly instructs
Babel to accept top-level await. As such, we can remove our special
configuration for our `ui/components/docs` folder, which we can now
safely preprocess.

DISABLE_THIRD_PARTY_CHECK=Karma fix
R=jacktfranklin@chromium.org

Bug: none
Change-Id: I0e96dce0117550f1a2db6a93654d8862d9cae95a
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3158226
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2021-09-13 14:22:17 +00:00

48 lines
1.1 KiB
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.parseAsync = exports.parseSync = exports.parse = void 0;
function _gensync() {
const data = require("gensync");
_gensync = function () {
return data;
};
return data;
}
var _config = require("./config");
var _parser = require("./parser");
var _normalizeOpts = require("./transformation/normalize-opts");
const parseRunner = _gensync()(function* parse(code, opts) {
const config = yield* (0, _config.default)(opts);
if (config === null) {
return null;
}
return yield* (0, _parser.default)(config.passes, (0, _normalizeOpts.default)(config), code);
});
const parse = function parse(code, opts, callback) {
if (typeof opts === "function") {
callback = opts;
opts = undefined;
}
if (callback === undefined) return parseRunner.sync(code, opts);
parseRunner.errback(code, opts, callback);
};
exports.parse = parse;
const parseSync = parseRunner.sync;
exports.parseSync = parseSync;
const parseAsync = parseRunner.async;
exports.parseAsync = parseAsync;