You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
1.0 KiB
30 lines
1.0 KiB
4 months ago
|
export declare class InvariantError extends Error {
|
||
|
framesToPop: number;
|
||
|
name: string;
|
||
|
constructor(message?: string | number);
|
||
|
}
|
||
|
export declare function invariant(condition: any, message?: string | number): asserts condition;
|
||
|
declare const verbosityLevels: readonly ["debug", "log", "warn", "error", "silent"];
|
||
|
export declare type VerbosityLevel = (typeof verbosityLevels)[number];
|
||
|
export declare type ConsoleMethodName = Exclude<VerbosityLevel, "silent">;
|
||
|
export declare namespace invariant {
|
||
|
const debug: {
|
||
|
(...data: any[]): void;
|
||
|
(message?: any, ...optionalParams: any[]): void;
|
||
|
};
|
||
|
const log: {
|
||
|
(...data: any[]): void;
|
||
|
(message?: any, ...optionalParams: any[]): void;
|
||
|
};
|
||
|
const warn: {
|
||
|
(...data: any[]): void;
|
||
|
(message?: any, ...optionalParams: any[]): void;
|
||
|
};
|
||
|
const error: {
|
||
|
(...data: any[]): void;
|
||
|
(message?: any, ...optionalParams: any[]): void;
|
||
|
};
|
||
|
}
|
||
|
export declare function setVerbosity(level: VerbosityLevel): VerbosityLevel;
|
||
|
export default invariant;
|