wip importer

This commit is contained in:
Carl-Gerhard Lindesvärd
2024-07-09 16:13:46 +02:00
committed by Carl-Gerhard Lindesvärd
parent ba381636a0
commit da856152c7
12 changed files with 829 additions and 2 deletions

View File

@@ -24,9 +24,11 @@ declare global {
window.op = (t, ...args) => {
// @ts-expect-error
const fn = op[t].bind(op);
const fn = op[t] ? op[t].bind(op) : undefined;
if (typeof fn === 'function') {
fn(...args);
} else {
console.warn(`op.js: ${t} is not a function`);
}
};
}