fix(cli/fmt_errors): Abbreviate long data URLs in stack traces (#12127)

Co-authored-by: Mike White <mike.white@auctane.com>
This commit is contained in:
Nayeem Rahman 2021-09-18 14:40:04 +01:00 committed by GitHub
parent f840906943
commit 75ca013f07
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 80 additions and 22 deletions

View file

@ -8,6 +8,10 @@
return core.opSync("op_format_diagnostic", diagnostics);
}
function opFormatFileName(location) {
return core.opSync("op_format_file_name", location);
}
function opApplySourceMap(location) {
const res = core.opSync("op_apply_source_map", location);
return {
@ -18,7 +22,8 @@
}
window.__bootstrap.errorStack = {
opApplySourceMap,
opFormatDiagnostics,
opFormatFileName,
opApplySourceMap,
};
})(this);