2025-03-21 19:59:16 +07:00
|
|
|
// Type definitions for things in this codebase ONLY!
|
|
|
|
|
|
|
|
|
|
declare global {
|
2025-07-10 12:39:25 +07:00
|
|
|
const __DEV__: boolean
|
2025-07-12 02:50:48 +07:00
|
|
|
const __BUILD_DISCORD_SERVER_URL__: string
|
|
|
|
|
const __BUILD_SOURCE_REPOSITORY_URL__: string
|
|
|
|
|
const __BUILD_LICENSE_URL__: string
|
2025-03-21 19:59:16 +07:00
|
|
|
const __BUILD_COMMIT__: string
|
2025-05-02 22:37:42 +07:00
|
|
|
const __BUILD_BRANCH__: string
|
2025-05-01 01:29:55 +07:00
|
|
|
const __BUILD_VERSION__: string
|
2025-03-21 19:59:16 +07:00
|
|
|
|
2025-06-12 23:25:10 +07:00
|
|
|
/**
|
|
|
|
|
* Whether to log promise rejections to the console.
|
|
|
|
|
*/
|
2025-05-05 19:13:05 +07:00
|
|
|
const __BUILD_FLAG_LOG_PROMISE_REJECTIONS__: boolean
|
2025-06-12 23:25:10 +07:00
|
|
|
/**
|
|
|
|
|
* Whether to debug module lookups.
|
|
|
|
|
*
|
2025-07-08 11:24:48 +07:00
|
|
|
* - Logs successful lookups.
|
2025-06-12 23:25:10 +07:00
|
|
|
* - Logs failed lookups with stack traces.
|
|
|
|
|
* - Logs partial matches (matches exportless, but not with-exports).
|
|
|
|
|
*/
|
2025-06-15 17:57:33 +07:00
|
|
|
const __BUILD_FLAG_DEBUG_MODULE_LOOKUPS__: boolean
|
2025-06-12 23:25:10 +07:00
|
|
|
/**
|
|
|
|
|
* Whether to debug proxified values.
|
|
|
|
|
*
|
|
|
|
|
* - Immediately calls the signal to initialize the proxified value.
|
|
|
|
|
* - Warns if the proxified value is nullish.
|
|
|
|
|
*/
|
2025-06-15 17:57:33 +07:00
|
|
|
const __BUILD_FLAG_DEBUG_PROXIFIED_VALUES__: boolean
|
2025-07-08 11:24:48 +07:00
|
|
|
/**
|
|
|
|
|
* Whether to debug module waits.
|
|
|
|
|
*
|
|
|
|
|
* - Logs when a module is waited for.
|
|
|
|
|
* - Logs when a module is found.
|
|
|
|
|
*/
|
|
|
|
|
const __BUILD_FLAG_DEBUG_MODULE_WAITS__: boolean
|
2025-06-08 19:01:33 +07:00
|
|
|
|
2025-05-22 00:06:36 +07:00
|
|
|
export interface ImportMeta {
|
2025-06-03 16:24:58 +07:00
|
|
|
glob<T = any>(
|
|
|
|
|
pattern: ImportMetaGlobPattern,
|
|
|
|
|
options?: ImportMetaGlobOptions,
|
|
|
|
|
): Record<string, () => Promise<T>>
|
2025-05-22 00:06:36 +07:00
|
|
|
glob<T = any>(
|
|
|
|
|
pattern: ImportMetaGlobPattern,
|
|
|
|
|
options: Extract<ImportMetaGlobOptions, { eager: true }>,
|
|
|
|
|
): Record<string, T>
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
interface ImportMetaGlobOptions {
|
|
|
|
|
eager?: boolean
|
|
|
|
|
import?: string
|
|
|
|
|
query?: string | Record<string, string>
|
2025-03-21 19:59:16 +07:00
|
|
|
}
|
2025-04-05 23:35:01 +07:00
|
|
|
|
2025-05-22 00:06:36 +07:00
|
|
|
type ImportMetaGlobPattern = string | string[]
|
|
|
|
|
|
2025-04-05 23:35:01 +07:00
|
|
|
export {}
|