Interface WindowOrWorkerGlobalScope
interface WindowOrWorkerGlobalScope {
caches: CacheStorage;
crossOriginIsolated: boolean;
crypto: Crypto;
indexedDB: IDBFactory;
isSecureContext: boolean;
origin: string;
performance: Performance;
atob(data: string): string;
btoa(data: string): string;
clearInterval(id: number | undefined): void;
clearTimeout(id: number | undefined): void;
createImageBitmap(
image: ImageBitmapSource,
options?: ImageBitmapOptions,
): Promise<ImageBitmap>;
createImageBitmap(
image: ImageBitmapSource,
sx: number,
sy: number,
sw: number,
sh: number,
options?: ImageBitmapOptions,
): Promise<ImageBitmap>;
fetch(input: URL | RequestInfo, init?: RequestInit): Promise<Response>;
queueMicrotask(callback: VoidFunction): void;
reportError(e: any): void;
setInterval(
handler: TimerHandler,
timeout?: number,
...arguments: any[],
): number;
setTimeout(
handler: TimerHandler,
timeout?: number,
...arguments: any[],
): number;
structuredClone<T = any>(value: T, options?: StructuredSerializeOptions): T;
}
caches: CacheStorage;
crossOriginIsolated: boolean;
crypto: Crypto;
indexedDB: IDBFactory;
isSecureContext: boolean;
origin: string;
performance: Performance;
atob(data: string): string;
btoa(data: string): string;
clearInterval(id: number | undefined): void;
clearTimeout(id: number | undefined): void;
createImageBitmap(
image: ImageBitmapSource,
options?: ImageBitmapOptions,
): Promise<ImageBitmap>;
createImageBitmap(
image: ImageBitmapSource,
sx: number,
sy: number,
sw: number,
sh: number,
options?: ImageBitmapOptions,
): Promise<ImageBitmap>;
fetch(input: URL | RequestInfo, init?: RequestInit): Promise<Response>;
queueMicrotask(callback: VoidFunction): void;
reportError(e: any): void;
setInterval(
handler: TimerHandler,
timeout?: number,
...arguments: any[],
): number;
setTimeout(
handler: TimerHandler,
timeout?: number,
...arguments: any[],
): number;
structuredClone<T = any>(value: T, options?: StructuredSerializeOptions): T;
}
Hierarchy
- WindowOrWorkerGlobalScope (View Summary)
Properties
Readonlycaches
ReadonlycrossOriginIsolated
crossOriginIsolated: boolean
Readonlycrypto
crypto: Crypto
ReadonlyindexedDB
ReadonlyisSecureContext
isSecureContext: boolean
Readonlyorigin
origin: string
Readonlyperformance
Methods
atob
btoa
clearInterval
clearTimeout
createImageBitmap
Parameters
- image: ImageBitmapSource
Optionaloptions: ImageBitmapOptions
Returns Promise<ImageBitmap>
- createImageBitmap(
image: ImageBitmapSource,
sx: number,
sy: number,
sw: number,
sh: number,
options?: ImageBitmapOptions,
): Promise<ImageBitmap>Parameters
- image: ImageBitmapSource
- sx: number
- sy: number
- sw: number
- sh: number
Optionaloptions: ImageBitmapOptions
Returns Promise<ImageBitmap>
fetch
queueMicrotask
reportError
setInterval
Parameters
- handler: TimerHandler
Optionaltimeout: number- ...arguments: any[]
Returns number
setTimeout
Parameters
- handler: TimerHandler
Optionaltimeout: number- ...arguments: any[]
Returns number
Available only in secure contexts.
MDN Reference