Handle KaTeX warnings (#13760)

Co-authored-by: Joe Mooring <joe.mooring@veriphor.com>

Fixes #13735
This commit is contained in:
Bjørn Erik Pedersen
2025-05-30 20:57:54 +02:00
committed by GitHub
parent 75259636c8
commit 6334948515
10 changed files with 76 additions and 15 deletions

View File

@@ -4,6 +4,15 @@ export function readInput(handle) {
let currentLine = [];
const buffer = new Uint8Array(buffSize);
// These are not implemented by QuickJS.
console.warn = (value) => {
console.log(value);
};
console.error = (value) => {
throw new Error(value);
};
// Read all the available bytes
while (true) {
// Stdin file descriptor