@lordfokas/magic-orm
Version:
A class-based ORM in TypeScript. Unorthodox and extremely opinionated, made to fit my specific use cases.
14 lines (13 loc) • 503 B
TypeScript
import { type Member } from './Structures.js';
declare global {
interface Object {
/** Check if an object is flat or a composite */
isHigherOrder: () => boolean;
}
interface Promise<T> {
/** For a Promise<any[ ]>, returns a promise with the first element or null */
first(): Promise<Member<T> | null>;
/** For a Promise<any[ ]>, returns a promise with the first element or fallback */
first(fallback: Member<T>): Promise<Member<T>>;
}
}