From c0cc240810f9280ca458c54b4cb69acc30e47e27 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Wed, 30 May 2018 18:59:50 +0200 Subject: [PATCH] Slightly better organization for deno module. --- deno.ts | 6 ++++++ runtime.ts | 10 +--------- 2 files changed, 7 insertions(+), 9 deletions(-) create mode 100644 deno.ts diff --git a/deno.ts b/deno.ts new file mode 100644 index 00000000000000..595d87709a3743 --- /dev/null +++ b/deno.ts @@ -0,0 +1,6 @@ +// Copyright 2018 Ryan Dahl +// All rights reserved. MIT License. +// Public deno module. +// TODO get rid of deno.d.ts +export { pub, sub } from "./dispatch"; +export { readFileSync, writeFileSync } from "./os"; diff --git a/runtime.ts b/runtime.ts index 1b6e7cfcd88467..fb64cd2b6d2dc7 100644 --- a/runtime.ts +++ b/runtime.ts @@ -12,20 +12,12 @@ import * as ts from "typescript"; import * as util from "./util"; import { log } from "./util"; import * as os from "./os"; -import { pub, sub } from "./dispatch"; import * as sourceMaps from "./v8_source_maps"; import { _global, globalEval } from "./globals"; +import * as deno from "./deno"; const EOL = "\n"; -// Public deno module. -const deno = { - pub, - sub, - readFileSync: os.readFileSync, - writeFileSync: os.writeFileSync -}; - // tslint:disable-next-line:no-any type AmdFactory = (...args: any[]) => undefined | object; type AmdDefine = (deps: string[], factory: AmdFactory) => void;