From f83aee02e66214853a008ebe4b5141405ac3a950 Mon Sep 17 00:00:00 2001 From: Kitson Kelly Date: Sat, 1 Sep 2018 07:45:26 -0700 Subject: Bundle most types into globals.d.ts (#642) --- js/globals.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'js/globals.ts') diff --git a/js/globals.ts b/js/globals.ts index 0364aaf98..b90aa46eb 100644 --- a/js/globals.ts +++ b/js/globals.ts @@ -2,7 +2,7 @@ import { Console } from "./console"; import * as timers from "./timers"; -import { TextDecoder, TextEncoder } from "./text_encoding"; +import * as textEncoding from "./text_encoding"; import * as fetch_ from "./fetch"; import { libdeno } from "./libdeno"; import { globalEval } from "./global-eval"; @@ -24,8 +24,8 @@ declare global { const fetch: typeof fetch_.fetch; // tslint:disable:variable-name - let TextEncoder: TextEncoder; - let TextDecoder: TextDecoder; + let TextEncoder: typeof textEncoding.TextEncoder; + let TextDecoder: typeof textEncoding.TextDecoder; // tslint:enable:variable-name } @@ -41,7 +41,7 @@ window.clearTimeout = timers.clearTimer; window.clearInterval = timers.clearTimer; window.console = new Console(libdeno.print); -window.TextEncoder = TextEncoder; -window.TextDecoder = TextDecoder; +window.TextEncoder = textEncoding.TextEncoder; +window.TextDecoder = textEncoding.TextDecoder; window.fetch = fetch_.fetch; -- cgit v1.2.3