Add Vencord Loading & tray icon

This commit is contained in:
Vendicated
2023-04-04 00:41:52 +02:00
parent 307051141d
commit f45d6482ac
12 changed files with 176 additions and 11 deletions

View File

@@ -0,0 +1 @@
export const GET_PRELOAD_FILE = "VCD_GET_PRELOAD_FILE";

View File

@@ -1,2 +0,0 @@

8
src/shared/utils/once.ts Normal file
View File

@@ -0,0 +1,8 @@
export function once<T extends Function>(fn: T): T {
let called = false;
return function (this: any, ...args: any[]) {
if (called) return;
called = true;
return fn.apply(this, args);
} as any;
}