Set up vs project
This commit is contained in:
Vendored
+20
@@ -0,0 +1,20 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
// Declare types that we probe for to implement util and/or polyfill functions
|
||||
|
||||
declare global {
|
||||
|
||||
interface IdleDeadline {
|
||||
readonly didTimeout: boolean;
|
||||
timeRemaining(): number;
|
||||
}
|
||||
|
||||
function requestIdleCallback(callback: (args: IdleDeadline) => void, options?: { timeout: number }): number;
|
||||
function cancelIdleCallback(handle: number): void;
|
||||
|
||||
}
|
||||
|
||||
export { }
|
||||
Vendored
+42
@@ -0,0 +1,42 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
declare class LoaderEvent {
|
||||
readonly type: number;
|
||||
readonly timestamp: number;
|
||||
readonly detail: string;
|
||||
}
|
||||
|
||||
declare const define: {
|
||||
(moduleName: string, dependencies: string[], callback: (...args: any[]) => any): any;
|
||||
(moduleName: string, dependencies: string[], definition: any): any;
|
||||
(moduleName: string, callback: (...args: any[]) => any): any;
|
||||
(moduleName: string, definition: any): any;
|
||||
(dependencies: string[], callback: (...args: any[]) => any): any;
|
||||
(dependencies: string[], definition: any): any;
|
||||
};
|
||||
|
||||
interface NodeRequire {
|
||||
/**
|
||||
* @deprecated use `FileAccess.asFileUri()` for node.js contexts or `FileAccess.asBrowserUri` for browser contexts.
|
||||
*/
|
||||
toUrl(path: string): string;
|
||||
|
||||
/**
|
||||
* @deprecated MUST not be used anymore
|
||||
*
|
||||
* With the move from AMD to ESM we cannot use this anymore. There will be NO MORE node require like this.
|
||||
*/
|
||||
__$__nodeRequire<T>(moduleName: string): T;
|
||||
|
||||
(dependencies: string[], callback: (...args: any[]) => any, errorback?: (err: any) => void): any;
|
||||
config(data: any): any;
|
||||
onError: Function;
|
||||
getStats?(): ReadonlyArray<LoaderEvent>;
|
||||
hasDependencyCycle?(): boolean;
|
||||
define(amdModuleId: string, dependencies: string[], callback: (...args: any[]) => any): any;
|
||||
}
|
||||
|
||||
declare var require: NodeRequire;
|
||||
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
/**
|
||||
* Thenable is a common denominator between ES6 promises, Q, jquery.Deferred, WinJS.Promise,
|
||||
* and others. This API makes no assumption about what promise library is being used which
|
||||
* enables reusing existing code without migrating to a specific promise implementation. Still,
|
||||
* we recommend the use of native promises which are available in VS Code.
|
||||
*/
|
||||
interface Thenable<T> extends PromiseLike<T> { }
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
// AMD2ESM mirgation relevant
|
||||
|
||||
/**
|
||||
* NLS Globals: these need to be defined in all contexts that make
|
||||
* use of our `nls.localize` and `nls.localize2` functions. This includes:
|
||||
* - Electron main process
|
||||
* - Electron window (renderer) process
|
||||
* - Utility Process
|
||||
* - Node.js
|
||||
* - Browser
|
||||
* - Web worker
|
||||
*
|
||||
* That is because during build time we strip out all english strings from
|
||||
* the resulting JS code and replace it with a <number> that is then looked
|
||||
* up from the `_VSCODE_NLS_MESSAGES` array.
|
||||
*/
|
||||
declare global {
|
||||
/**
|
||||
* All NLS messages produced by `localize` and `localize2` calls
|
||||
* under `src/vs` translated to the language as indicated by
|
||||
* `_VSCODE_NLS_LANGUAGE`.
|
||||
*/
|
||||
var _VSCODE_NLS_MESSAGES: string[];
|
||||
/**
|
||||
* The actual language of the NLS messages (e.g. 'en', de' or 'pt-br').
|
||||
*/
|
||||
var _VSCODE_NLS_LANGUAGE: string | undefined;
|
||||
}
|
||||
|
||||
// fake export to make global work
|
||||
export { }
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
// AMD2ESM mirgation relevant
|
||||
|
||||
declare global {
|
||||
|
||||
/**
|
||||
* Holds the file root for resources.
|
||||
*/
|
||||
var _VSCODE_FILE_ROOT: string;
|
||||
|
||||
/**
|
||||
* CSS loader that's available during development time.
|
||||
* DO NOT call directly, instead just import css modules, like `import 'some.css'`
|
||||
*/
|
||||
var _VSCODE_CSS_LOAD: (module: string) => void;
|
||||
|
||||
/**
|
||||
* @deprecated You MUST use `IProductService` whenever possible.
|
||||
*/
|
||||
var _VSCODE_PRODUCT_JSON: Record<string, any>;
|
||||
/**
|
||||
* @deprecated You MUST use `IProductService` whenever possible.
|
||||
*/
|
||||
var _VSCODE_PACKAGE_JSON: Record<string, any>;
|
||||
|
||||
}
|
||||
|
||||
// fake export to make global work
|
||||
export { }
|
||||
Reference in New Issue
Block a user