From 8ef3beee6356bf2c8b2ab3802d4e8833abb0a8ee Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 20 Aug 2021 10:21:29 +0200 Subject: [PATCH] Move extra `monaco.d.ts` content to the recipe file --- build/gulpfile.editor.js | 8 +------- build/monaco/monaco.d.ts.recipe | 4 ++++ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/build/gulpfile.editor.js b/build/gulpfile.editor.js index d60adad2e26..230082e4ad9 100644 --- a/build/gulpfile.editor.js +++ b/build/gulpfile.editor.js @@ -230,13 +230,7 @@ function toExternalDTS(contents) { } if (line.indexOf('declare let MonacoEnvironment') === 0) { - lines[i] = `declare global { - let MonacoEnvironment: Environment | undefined; - - interface Window { - MonacoEnvironment?: monaco.Environment | undefined; - } -}`; + lines[i] = `declare global {\n let MonacoEnvironment: Environment | undefined;\n}`; // lines[i] = line.replace('declare namespace monaco.', 'export namespace '); } } diff --git a/build/monaco/monaco.d.ts.recipe b/build/monaco/monaco.d.ts.recipe index bb053136f42..45812b95933 100644 --- a/build/monaco/monaco.d.ts.recipe +++ b/build/monaco/monaco.d.ts.recipe @@ -5,6 +5,10 @@ declare let MonacoEnvironment: monaco.Environment | undefined; +interface Window { + MonacoEnvironment?: monaco.Environment | undefined; +} + declare namespace monaco { export type Thenable = PromiseLike;