diff --git a/typings/globals.d.ts b/typings/globals.d.ts index bc47c08b02b376..52b64bf9c344b2 100644 --- a/typings/globals.d.ts +++ b/typings/globals.d.ts @@ -16,19 +16,6 @@ import {URLBinding} from "./internalBinding/url"; import {UtilBinding} from "./internalBinding/util"; import {WorkerBinding} from "./internalBinding/worker"; -declare type TypedArray = - | Uint8Array - | Uint8ClampedArray - | Uint16Array - | Uint32Array - | Int8Array - | Int16Array - | Int32Array - | Float32Array - | Float64Array - | BigUint64Array - | BigInt64Array; - interface InternalBindingMap { async_wrap: AsyncWrapBinding; blob: BlobBinding; @@ -54,6 +41,19 @@ type InternalBindingKeys = keyof InternalBindingMap; declare function internalBinding(binding: T): InternalBindingMap[T] declare global { + type TypedArray = + | Uint8Array + | Uint8ClampedArray + | Uint16Array + | Uint32Array + | Int8Array + | Int16Array + | Int32Array + | Float32Array + | Float64Array + | BigUint64Array + | BigInt64Array; + namespace NodeJS { interface Global { internalBinding(binding: T): InternalBindingMap[T]