@codingame/monaco-editor-wrapper 1.7.0 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/dist/Groovy2.js +28 -0
  2. package/dist/features/mutualizedExtensionConfigurations.d.ts +1 -0
  3. package/dist/features/mutualizedExtensionConfigurations.js +4857 -0
  4. package/dist/languages/extensions/configurationLoader.d.ts +20 -2
  5. package/dist/languages/index.d.ts +2 -1
  6. package/dist/languages/textMate/index.d.ts +1 -1
  7. package/dist/main.js +26 -10
  8. package/dist/markdown-basics-markdown.js +18 -0
  9. package/dist/services/CustomFoldingRulesLanguageConfigurationService.d.ts +4 -0
  10. package/dist/verilog-systemverilog.js +140 -327
  11. package/dist/verilog2.js +65 -56
  12. package/dist/vscode-R-rmd.js +2 -2
  13. package/package.json +1 -2
  14. package/stats.html +1 -1
  15. package/dist/COBOL Copybook2.js +0 -2017
  16. package/dist/COBOL2.js +0 -2017
  17. package/dist/SQL.plist.js +0 -482
  18. package/dist/bsv2.js +0 -49
  19. package/dist/c2.js +0 -18
  20. package/dist/coffeescript2.js +0 -18
  21. package/dist/configuration/hack.d.ts +0 -2
  22. package/dist/cpp2.js +0 -18
  23. package/dist/csharp2.js +0 -508
  24. package/dist/cssContribution.js +0 -10
  25. package/dist/diet3.js +0 -92
  26. package/dist/extensionConfigurations.js +0 -9475
  27. package/dist/fsharp2.js +0 -18
  28. package/dist/groovy2.js +0 -229
  29. package/dist/html (eex).js +0 -31
  30. package/dist/htmlContribution.js +0 -10
  31. package/dist/javascript2.js +0 -196
  32. package/dist/javascriptreact2.js +0 -196
  33. package/dist/jsonContribution.js +0 -78
  34. package/dist/kotlin2.js +0 -117
  35. package/dist/kotlinscript2.js +0 -117
  36. package/dist/languages/monarch/list.d.ts +0 -7
  37. package/dist/languages/textMate/TextMateTokensProvider.d.ts +0 -11
  38. package/dist/markdown-basics.js +0 -103
  39. package/dist/markdown2.js +0 -103
  40. package/dist/pgsql-sql.js +0 -21
  41. package/dist/pgsql.js +0 -21
  42. package/dist/php2.js +0 -265
  43. package/dist/powershell2.js +0 -18
  44. package/dist/r.tmLanguage.js +0 -572
  45. package/dist/reason2.js +0 -100
  46. package/dist/services/functional.d.ts +0 -1
  47. package/dist/services/lyfecycle.d.ts +0 -13
  48. package/dist/sql2.js +0 -21
  49. package/dist/swift2.js +0 -183
  50. package/dist/systemverilog2.js +0 -208
  51. package/dist/tcl2.js +0 -151
  52. package/dist/typescript-basics.js +0 -312
  53. package/dist/typescript2.js +0 -312
  54. package/dist/typescriptContribution.js +0 -36
  55. package/dist/typescriptreact2.js +0 -312
  56. package/dist/vb2.js +0 -88
@@ -1,36 +0,0 @@
1
- import 'monaco-editor/esm/vs/language/typescript/monaco.contribution';
2
- import * as monaco from 'monaco-editor/esm/vs/editor/edcore.main';
3
- import { r as registerWorkerLoader } from './worker.js';
4
-
5
- var typescriptGlobal = "// Declare \"static\" methods in Error\ninterface ErrorConstructor {\n /** Create .stack property on a target object */\n captureStackTrace(targetObject: object, constructorOpt?: Function): void;\n\n /**\n * Optional override for formatting stack traces\n *\n * @see https://github.com/v8/v8/wiki/Stack%20Trace%20API#customizing-stack-traces\n */\n prepareStackTrace?: (err: Error, stackTraces: NodeJS.CallSite[]) => any;\n\n stackTraceLimit: number;\n}\n\n// Node.js ESNEXT support\ninterface String {\n /** Removes whitespace from the left end of a string. */\n trimLeft(): string;\n /** Removes whitespace from the right end of a string. */\n trimRight(): string;\n\n /** Returns a copy with leading whitespace removed. */\n trimStart(): string;\n /** Returns a copy with trailing whitespace removed. */\n trimEnd(): string;\n}\n\ninterface ImportMeta {\n url: string;\n}\n\n/*-----------------------------------------------*\n * *\n * GLOBAL *\n * *\n ------------------------------------------------*/\n\n// For backwards compability\ninterface NodeRequire extends NodeJS.Require {}\ninterface RequireResolve extends NodeJS.RequireResolve {}\ninterface NodeModule extends NodeJS.Module {}\n\ndeclare var process: NodeJS.Process;\ndeclare var console: Console;\n\ndeclare var __filename: string;\ndeclare var __dirname: string;\n\ndeclare function setTimeout(callback: (...args: any[]) => void, ms?: number, ...args: any[]): NodeJS.Timeout;\ndeclare namespace setTimeout {\n function __promisify__(ms: number): Promise<void>;\n function __promisify__<T>(ms: number, value: T): Promise<T>;\n}\ndeclare function clearTimeout(timeoutId: NodeJS.Timeout): void;\ndeclare function setInterval(callback: (...args: any[]) => void, ms?: number, ...args: any[]): NodeJS.Timeout;\ndeclare function clearInterval(intervalId: NodeJS.Timeout): void;\ndeclare function setImmediate(callback: (...args: any[]) => void, ...args: any[]): NodeJS.Immediate;\ndeclare namespace setImmediate {\n function __promisify__(): Promise<void>;\n function __promisify__<T>(value: T): Promise<T>;\n}\ndeclare function clearImmediate(immediateId: NodeJS.Immediate): void;\n\ndeclare function queueMicrotask(callback: () => void): void;\n\ndeclare var require: NodeRequire;\ndeclare var module: NodeModule;\n\n// Same as module.exports\ndeclare var exports: any;\n\n// Buffer class\ntype BufferEncoding = \"ascii\" | \"utf8\" | \"utf-8\" | \"utf16le\" | \"ucs2\" | \"ucs-2\" | \"base64\" | \"latin1\" | \"binary\" | \"hex\";\n\ntype WithImplicitCoercion<T> = T | { valueOf(): T };\n\n/**\n * Raw data is stored in instances of the Buffer class.\n * A Buffer is similar to an array of integers but corresponds to a raw memory allocation outside the V8 heap. A Buffer cannot be resized.\n * Valid string encodings: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex'\n */\ndeclare class Buffer extends Uint8Array {\n /**\n * Allocates a new buffer containing the given {str}.\n *\n * @param str String to store in buffer.\n * @param encoding encoding to use, optional. Default is 'utf8'\n * @deprecated since v10.0.0 - Use `Buffer.from(string[, encoding])` instead.\n */\n constructor(str: string, encoding?: BufferEncoding);\n /**\n * Allocates a new buffer of {size} octets.\n *\n * @param size count of octets to allocate.\n * @deprecated since v10.0.0 - Use `Buffer.alloc()` instead (also see `Buffer.allocUnsafe()`).\n */\n constructor(size: number);\n /**\n * Allocates a new buffer containing the given {array} of octets.\n *\n * @param array The octets to store.\n * @deprecated since v10.0.0 - Use `Buffer.from(array)` instead.\n */\n constructor(array: Uint8Array);\n /**\n * Produces a Buffer backed by the same allocated memory as\n * the given {ArrayBuffer}/{SharedArrayBuffer}.\n *\n *\n * @param arrayBuffer The ArrayBuffer with which to share memory.\n * @deprecated since v10.0.0 - Use `Buffer.from(arrayBuffer[, byteOffset[, length]])` instead.\n */\n constructor(arrayBuffer: ArrayBuffer | SharedArrayBuffer);\n /**\n * Allocates a new buffer containing the given {array} of octets.\n *\n * @param array The octets to store.\n * @deprecated since v10.0.0 - Use `Buffer.from(array)` instead.\n */\n constructor(array: ReadonlyArray<any>);\n /**\n * Copies the passed {buffer} data onto a new {Buffer} instance.\n *\n * @param buffer The buffer to copy.\n * @deprecated since v10.0.0 - Use `Buffer.from(buffer)` instead.\n */\n constructor(buffer: Buffer);\n /**\n * When passed a reference to the .buffer property of a TypedArray instance,\n * the newly created Buffer will share the same allocated memory as the TypedArray.\n * The optional {byteOffset} and {length} arguments specify a memory range\n * within the {arrayBuffer} that will be shared by the Buffer.\n *\n * @param arrayBuffer The .buffer property of any TypedArray or a new ArrayBuffer()\n */\n static from(arrayBuffer: WithImplicitCoercion<ArrayBuffer | SharedArrayBuffer>, byteOffset?: number, length?: number): Buffer;\n /**\n * Creates a new Buffer using the passed {data}\n * @param data data to create a new Buffer\n */\n static from(data: Uint8Array | ReadonlyArray<number>): Buffer;\n static from(data: WithImplicitCoercion<Uint8Array | ReadonlyArray<number> | string>): Buffer;\n /**\n * Creates a new Buffer containing the given JavaScript string {str}.\n * If provided, the {encoding} parameter identifies the character encoding.\n * If not provided, {encoding} defaults to 'utf8'.\n */\n static from(str: WithImplicitCoercion<string> | { [Symbol.toPrimitive](hint: 'string'): string }, encoding?: BufferEncoding): Buffer;\n /**\n * Creates a new Buffer using the passed {data}\n * @param values to create a new Buffer\n */\n static of(...items: number[]): Buffer;\n /**\n * Returns true if {obj} is a Buffer\n *\n * @param obj object to test.\n */\n static isBuffer(obj: any): obj is Buffer;\n /**\n * Returns true if {encoding} is a valid encoding argument.\n * Valid string encodings in Node 0.12: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex'\n *\n * @param encoding string to test.\n */\n static isEncoding(encoding: string): encoding is BufferEncoding;\n /**\n * Gives the actual byte length of a string. encoding defaults to 'utf8'.\n * This is not the same as String.prototype.length since that returns the number of characters in a string.\n *\n * @param string string to test.\n * @param encoding encoding used to evaluate (defaults to 'utf8')\n */\n static byteLength(\n string: string | NodeJS.ArrayBufferView | ArrayBuffer | SharedArrayBuffer,\n encoding?: BufferEncoding\n ): number;\n /**\n * Returns a buffer which is the result of concatenating all the buffers in the list together.\n *\n * If the list has no items, or if the totalLength is 0, then it returns a zero-length buffer.\n * If the list has exactly one item, then the first item of the list is returned.\n * If the list has more than one item, then a new Buffer is created.\n *\n * @param list An array of Buffer objects to concatenate\n * @param totalLength Total length of the buffers when concatenated.\n * If totalLength is not provided, it is read from the buffers in the list. However, this adds an additional loop to the function, so it is faster to provide the length explicitly.\n */\n static concat(list: ReadonlyArray<Uint8Array>, totalLength?: number): Buffer;\n /**\n * The same as buf1.compare(buf2).\n */\n static compare(buf1: Uint8Array, buf2: Uint8Array): number;\n /**\n * Allocates a new buffer of {size} octets.\n *\n * @param size count of octets to allocate.\n * @param fill if specified, buffer will be initialized by calling buf.fill(fill).\n * If parameter is omitted, buffer will be filled with zeros.\n * @param encoding encoding used for call to buf.fill while initalizing\n */\n static alloc(size: number, fill?: string | Buffer | number, encoding?: BufferEncoding): Buffer;\n /**\n * Allocates a new buffer of {size} octets, leaving memory not initialized, so the contents\n * of the newly created Buffer are unknown and may contain sensitive data.\n *\n * @param size count of octets to allocate\n */\n static allocUnsafe(size: number): Buffer;\n /**\n * Allocates a new non-pooled buffer of {size} octets, leaving memory not initialized, so the contents\n * of the newly created Buffer are unknown and may contain sensitive data.\n *\n * @param size count of octets to allocate\n */\n static allocUnsafeSlow(size: number): Buffer;\n /**\n * This is the number of bytes used to determine the size of pre-allocated, internal Buffer instances used for pooling. This value may be modified.\n */\n static poolSize: number;\n\n write(string: string, encoding?: BufferEncoding): number;\n write(string: string, offset: number, encoding?: BufferEncoding): number;\n write(string: string, offset: number, length: number, encoding?: BufferEncoding): number;\n toString(encoding?: BufferEncoding, start?: number, end?: number): string;\n toJSON(): { type: 'Buffer'; data: number[] };\n equals(otherBuffer: Uint8Array): boolean;\n compare(\n otherBuffer: Uint8Array,\n targetStart?: number,\n targetEnd?: number,\n sourceStart?: number,\n sourceEnd?: number\n ): number;\n copy(targetBuffer: Uint8Array, targetStart?: number, sourceStart?: number, sourceEnd?: number): number;\n /**\n * Returns a new `Buffer` that references **the same memory as the original**, but offset and cropped by the start and end indices.\n *\n * This method is incompatible with `Uint8Array#slice()`, which returns a copy of the original memory.\n *\n * @param begin Where the new `Buffer` will start. Default: `0`.\n * @param end Where the new `Buffer` will end (not inclusive). Default: `buf.length`.\n */\n slice(begin?: number, end?: number): Buffer;\n /**\n * Returns a new `Buffer` that references **the same memory as the original**, but offset and cropped by the start and end indices.\n *\n * This method is compatible with `Uint8Array#subarray()`.\n *\n * @param begin Where the new `Buffer` will start. Default: `0`.\n * @param end Where the new `Buffer` will end (not inclusive). Default: `buf.length`.\n */\n subarray(begin?: number, end?: number): Buffer;\n writeBigInt64BE(value: bigint, offset?: number): number;\n writeBigInt64LE(value: bigint, offset?: number): number;\n writeBigUInt64BE(value: bigint, offset?: number): number;\n writeBigUInt64LE(value: bigint, offset?: number): number;\n writeUIntLE(value: number, offset: number, byteLength: number): number;\n writeUIntBE(value: number, offset: number, byteLength: number): number;\n writeIntLE(value: number, offset: number, byteLength: number): number;\n writeIntBE(value: number, offset: number, byteLength: number): number;\n readBigUInt64BE(offset?: number): bigint;\n readBigUInt64LE(offset?: number): bigint;\n readBigInt64BE(offset?: number): bigint;\n readBigInt64LE(offset?: number): bigint;\n readUIntLE(offset: number, byteLength: number): number;\n readUIntBE(offset: number, byteLength: number): number;\n readIntLE(offset: number, byteLength: number): number;\n readIntBE(offset: number, byteLength: number): number;\n readUInt8(offset?: number): number;\n readUInt16LE(offset?: number): number;\n readUInt16BE(offset?: number): number;\n readUInt32LE(offset?: number): number;\n readUInt32BE(offset?: number): number;\n readInt8(offset?: number): number;\n readInt16LE(offset?: number): number;\n readInt16BE(offset?: number): number;\n readInt32LE(offset?: number): number;\n readInt32BE(offset?: number): number;\n readFloatLE(offset?: number): number;\n readFloatBE(offset?: number): number;\n readDoubleLE(offset?: number): number;\n readDoubleBE(offset?: number): number;\n reverse(): this;\n swap16(): Buffer;\n swap32(): Buffer;\n swap64(): Buffer;\n writeUInt8(value: number, offset?: number): number;\n writeUInt16LE(value: number, offset?: number): number;\n writeUInt16BE(value: number, offset?: number): number;\n writeUInt32LE(value: number, offset?: number): number;\n writeUInt32BE(value: number, offset?: number): number;\n writeInt8(value: number, offset?: number): number;\n writeInt16LE(value: number, offset?: number): number;\n writeInt16BE(value: number, offset?: number): number;\n writeInt32LE(value: number, offset?: number): number;\n writeInt32BE(value: number, offset?: number): number;\n writeFloatLE(value: number, offset?: number): number;\n writeFloatBE(value: number, offset?: number): number;\n writeDoubleLE(value: number, offset?: number): number;\n writeDoubleBE(value: number, offset?: number): number;\n\n fill(value: string | Uint8Array | number, offset?: number, end?: number, encoding?: BufferEncoding): this;\n\n indexOf(value: string | number | Uint8Array, byteOffset?: number, encoding?: BufferEncoding): number;\n lastIndexOf(value: string | number | Uint8Array, byteOffset?: number, encoding?: BufferEncoding): number;\n entries(): IterableIterator<[number, number]>;\n includes(value: string | number | Buffer, byteOffset?: number, encoding?: BufferEncoding): boolean;\n keys(): IterableIterator<number>;\n values(): IterableIterator<number>;\n}\n\n/*----------------------------------------------*\n* *\n* GLOBAL INTERFACES *\n* *\n*-----------------------------------------------*/\ndeclare namespace NodeJS {\n interface InspectOptions {\n /**\n * If set to `true`, getters are going to be\n * inspected as well. If set to `'get'` only getters without setter are going\n * to be inspected. If set to `'set'` only getters having a corresponding\n * setter are going to be inspected. This might cause side effects depending on\n * the getter function.\n * @default `false`\n */\n getters?: 'get' | 'set' | boolean;\n showHidden?: boolean;\n /**\n * @default 2\n */\n depth?: number | null;\n colors?: boolean;\n customInspect?: boolean;\n showProxy?: boolean;\n maxArrayLength?: number | null;\n /**\n * Specifies the maximum number of characters to\n * include when formatting. Set to `null` or `Infinity` to show all elements.\n * Set to `0` or negative to show no characters.\n * @default Infinity\n */\n maxStringLength?: number | null;\n breakLength?: number;\n /**\n * Setting this to `false` causes each object key\n * to be displayed on a new line. It will also add new lines to text that is\n * longer than `breakLength`. If set to a number, the most `n` inner elements\n * are united on a single line as long as all properties fit into\n * `breakLength`. Short array elements are also grouped together. Note that no\n * text will be reduced below 16 characters, no matter the `breakLength` size.\n * For more information, see the example below.\n * @default `true`\n */\n compact?: boolean | number;\n sorted?: boolean | ((a: string, b: string) => number);\n }\n\n interface CallSite {\n /**\n * Value of \"this\"\n */\n getThis(): any;\n\n /**\n * Type of \"this\" as a string.\n * This is the name of the function stored in the constructor field of\n * \"this\", if available. Otherwise the object's [[Class]] internal\n * property.\n */\n getTypeName(): string | null;\n\n /**\n * Current function\n */\n getFunction(): Function | undefined;\n\n /**\n * Name of the current function, typically its name property.\n * If a name property is not available an attempt will be made to try\n * to infer a name from the function's context.\n */\n getFunctionName(): string | null;\n\n /**\n * Name of the property [of \"this\" or one of its prototypes] that holds\n * the current function\n */\n getMethodName(): string | null;\n\n /**\n * Name of the script [if this function was defined in a script]\n */\n getFileName(): string | null;\n\n /**\n * Current line number [if this function was defined in a script]\n */\n getLineNumber(): number | null;\n\n /**\n * Current column number [if this function was defined in a script]\n */\n getColumnNumber(): number | null;\n\n /**\n * A call site object representing the location where eval was called\n * [if this function was created using a call to eval]\n */\n getEvalOrigin(): string | undefined;\n\n /**\n * Is this a toplevel invocation, that is, is \"this\" the global object?\n */\n isToplevel(): boolean;\n\n /**\n * Does this call take place in code defined by a call to eval?\n */\n isEval(): boolean;\n\n /**\n * Is this call in native V8 code?\n */\n isNative(): boolean;\n\n /**\n * Is this a constructor call?\n */\n isConstructor(): boolean;\n }\n\n interface ErrnoException extends Error {\n errno?: number;\n code?: string;\n path?: string;\n syscall?: string;\n stack?: string;\n }\n\n interface ReadableStream extends EventEmitter {\n readable: boolean;\n read(size?: number): string | Buffer;\n setEncoding(encoding: BufferEncoding): this;\n pause(): this;\n resume(): this;\n isPaused(): boolean;\n pipe<T extends WritableStream>(destination: T, options?: { end?: boolean; }): T;\n unpipe(destination?: WritableStream): this;\n unshift(chunk: string | Uint8Array, encoding?: BufferEncoding): void;\n wrap(oldStream: ReadableStream): this;\n [Symbol.asyncIterator](): AsyncIterableIterator<string | Buffer>;\n }\n\n interface WritableStream extends EventEmitter {\n writable: boolean;\n write(buffer: Uint8Array | string, cb?: (err?: Error | null) => void): boolean;\n write(str: string, encoding?: BufferEncoding, cb?: (err?: Error | null) => void): boolean;\n end(cb?: () => void): void;\n end(data: string | Uint8Array, cb?: () => void): void;\n end(str: string, encoding?: BufferEncoding, cb?: () => void): void;\n }\n\n interface ReadWriteStream extends ReadableStream, WritableStream { }\n\n interface Global {\n Array: typeof Array;\n ArrayBuffer: typeof ArrayBuffer;\n Boolean: typeof Boolean;\n Buffer: typeof Buffer;\n DataView: typeof DataView;\n Date: typeof Date;\n Error: typeof Error;\n EvalError: typeof EvalError;\n Float32Array: typeof Float32Array;\n Float64Array: typeof Float64Array;\n Function: typeof Function;\n Infinity: typeof Infinity;\n Int16Array: typeof Int16Array;\n Int32Array: typeof Int32Array;\n Int8Array: typeof Int8Array;\n Intl: typeof Intl;\n JSON: typeof JSON;\n Map: MapConstructor;\n Math: typeof Math;\n NaN: typeof NaN;\n Number: typeof Number;\n Object: typeof Object;\n Promise: typeof Promise;\n RangeError: typeof RangeError;\n ReferenceError: typeof ReferenceError;\n RegExp: typeof RegExp;\n Set: SetConstructor;\n String: typeof String;\n Symbol: Function;\n SyntaxError: typeof SyntaxError;\n TypeError: typeof TypeError;\n URIError: typeof URIError;\n Uint16Array: typeof Uint16Array;\n Uint32Array: typeof Uint32Array;\n Uint8Array: typeof Uint8Array;\n Uint8ClampedArray: typeof Uint8ClampedArray;\n WeakMap: WeakMapConstructor;\n WeakSet: WeakSetConstructor;\n clearImmediate: (immediateId: Immediate) => void;\n clearInterval: (intervalId: Timeout) => void;\n clearTimeout: (timeoutId: Timeout) => void;\n decodeURI: typeof decodeURI;\n decodeURIComponent: typeof decodeURIComponent;\n encodeURI: typeof encodeURI;\n encodeURIComponent: typeof encodeURIComponent;\n escape: (str: string) => string;\n eval: typeof eval;\n global: Global;\n isFinite: typeof isFinite;\n isNaN: typeof isNaN;\n parseFloat: typeof parseFloat;\n parseInt: typeof parseInt;\n setImmediate: (callback: (...args: any[]) => void, ...args: any[]) => Immediate;\n setInterval: (callback: (...args: any[]) => void, ms?: number, ...args: any[]) => Timeout;\n setTimeout: (callback: (...args: any[]) => void, ms?: number, ...args: any[]) => Timeout;\n queueMicrotask: typeof queueMicrotask;\n undefined: typeof undefined;\n unescape: (str: string) => string;\n gc: () => void;\n v8debug?: any;\n }\n\n interface RefCounted {\n ref(): this;\n unref(): this;\n }\n\n // compatibility with older typings\n interface Timer extends RefCounted {\n hasRef(): boolean;\n refresh(): this;\n [Symbol.toPrimitive](): number;\n }\n\n interface Immediate extends RefCounted {\n hasRef(): boolean;\n _onImmediate: Function; // to distinguish it from the Timeout class\n }\n\n interface Timeout extends Timer {\n hasRef(): boolean;\n refresh(): this;\n [Symbol.toPrimitive](): number;\n }\n\n type TypedArray =\n | Uint8Array\n | Uint8ClampedArray\n | Uint16Array\n | Uint32Array\n | Int8Array\n | Int16Array\n | Int32Array\n | BigUint64Array\n | BigInt64Array\n | Float32Array\n | Float64Array;\n type ArrayBufferView = TypedArray | DataView;\n\n interface Require {\n (id: string): any;\n resolve: RequireResolve;\n cache: Dict<NodeModule>;\n /**\n * @deprecated\n */\n extensions: RequireExtensions;\n main: Module | undefined;\n }\n\n interface RequireResolve {\n (id: string, options?: { paths?: string[]; }): string;\n paths(request: string): string[] | null;\n }\n\n interface RequireExtensions extends Dict<(m: Module, filename: string) => any> {\n '.js': (m: Module, filename: string) => any;\n '.json': (m: Module, filename: string) => any;\n '.node': (m: Module, filename: string) => any;\n }\n interface Module {\n exports: any;\n require: Require;\n id: string;\n filename: string;\n loaded: boolean;\n /** @deprecated since 14.6.0 Please use `require.main` and `module.children` instead. */\n parent: Module | null | undefined;\n children: Module[];\n /**\n * @since 11.14.0\n *\n * The directory name of the module. This is usually the same as the path.dirname() of the module.id.\n */\n path: string;\n paths: string[];\n }\n\n interface Dict<T> {\n [key: string]: T | undefined;\n }\n\n interface ReadOnlyDict<T> {\n readonly [key: string]: T | undefined;\n }\n}\n";
6
-
7
- var typescriptConsole = "declare module 'node:console' {\n export = console;\n}\n\ndeclare module 'console' {\n import { InspectOptions } from 'node:util';\n\n global {\n // This needs to be global to avoid TS2403 in case lib.dom.d.ts is present in the same build\n interface Console {\n Console: NodeJS.ConsoleConstructor;\n /**\n * A simple assertion test that verifies whether `value` is truthy.\n * If it is not, an `AssertionError` is thrown.\n * If provided, the error `message` is formatted using `util.format()` and used as the error message.\n */\n assert(value: any, message?: string, ...optionalParams: any[]): void;\n /**\n * When `stdout` is a TTY, calling `console.clear()` will attempt to clear the TTY.\n * When `stdout` is not a TTY, this method does nothing.\n */\n clear(): void;\n /**\n * Maintains an internal counter specific to `label` and outputs to `stdout` the number of times `console.count()` has been called with the given `label`.\n */\n count(label?: string): void;\n /**\n * Resets the internal counter specific to `label`.\n */\n countReset(label?: string): void;\n /**\n * The `console.debug()` function is an alias for {@link console.log()}.\n */\n debug(message?: any, ...optionalParams: any[]): void;\n /**\n * Uses {@link util.inspect()} on `obj` and prints the resulting string to `stdout`.\n * This function bypasses any custom `inspect()` function defined on `obj`.\n */\n dir(obj: any, options?: InspectOptions): void;\n /**\n * This method calls {@link console.log()} passing it the arguments received. Please note that this method does not produce any XML formatting\n */\n dirxml(...data: any[]): void;\n /**\n * Prints to `stderr` with newline.\n */\n error(message?: any, ...optionalParams: any[]): void;\n /**\n * Increases indentation of subsequent lines by two spaces.\n * If one or more `label`s are provided, those are printed first without the additional indentation.\n */\n group(...label: any[]): void;\n /**\n * The `console.groupCollapsed()` function is an alias for {@link console.group()}.\n */\n groupCollapsed(...label: any[]): void;\n /**\n * Decreases indentation of subsequent lines by two spaces.\n */\n groupEnd(): void;\n /**\n * The {@link console.info()} function is an alias for {@link console.log()}.\n */\n info(message?: any, ...optionalParams: any[]): void;\n /**\n * Prints to `stdout` with newline.\n */\n log(message?: any, ...optionalParams: any[]): void;\n /**\n * This method does not display anything unless used in the inspector.\n * Prints to `stdout` the array `array` formatted as a table.\n */\n table(tabularData: any, properties?: ReadonlyArray<string>): void;\n /**\n * Starts a timer that can be used to compute the duration of an operation. Timers are identified by a unique `label`.\n */\n time(label?: string): void;\n /**\n * Stops a timer that was previously started by calling {@link console.time()} and prints the result to `stdout`.\n */\n timeEnd(label?: string): void;\n /**\n * For a timer that was previously started by calling {@link console.time()}, prints the elapsed time and other `data` arguments to `stdout`.\n */\n timeLog(label?: string, ...data: any[]): void;\n /**\n * Prints to `stderr` the string 'Trace :', followed by the {@link util.format()} formatted message and stack trace to the current position in the code.\n */\n trace(message?: any, ...optionalParams: any[]): void;\n /**\n * The {@link console.warn()} function is an alias for {@link console.error()}.\n */\n warn(message?: any, ...optionalParams: any[]): void;\n\n // --- Inspector mode only ---\n /**\n * This method does not display anything unless used in the inspector.\n * Starts a JavaScript CPU profile with an optional label.\n */\n profile(label?: string): void;\n /**\n * This method does not display anything unless used in the inspector.\n * Stops the current JavaScript CPU profiling session if one has been started and prints the report to the Profiles panel of the inspector.\n */\n profileEnd(label?: string): void;\n /**\n * This method does not display anything unless used in the inspector.\n * Adds an event with the label `label` to the Timeline panel of the inspector.\n */\n timeStamp(label?: string): void;\n }\n\n var console: Console;\n\n namespace NodeJS {\n interface ConsoleConstructorOptions {\n stdout: WritableStream;\n stderr?: WritableStream;\n ignoreErrors?: boolean;\n colorMode?: boolean | 'auto';\n inspectOptions?: InspectOptions;\n }\n\n interface ConsoleConstructor {\n prototype: Console;\n new(stdout: WritableStream, stderr?: WritableStream, ignoreErrors?: boolean): Console;\n new(options: ConsoleConstructorOptions): Console;\n }\n\n interface Global {\n console: typeof console;\n }\n }\n }\n\n export = console;\n}\n";
8
-
9
- var typescriptProcess = "declare module 'node:process' {\n export = process;\n}\n\ndeclare module 'process' {\n import * as tty from 'node:tty';\n\n global {\n var process: NodeJS.Process;\n\n namespace NodeJS {\n // this namespace merge is here because these are specifically used\n // as the type for process.stdin, process.stdout, and process.stderr.\n // they can't live in tty.d.ts because we need to disambiguate the imported name.\n interface ReadStream extends tty.ReadStream {}\n interface WriteStream extends tty.WriteStream {}\n\n interface MemoryUsage {\n rss: number;\n heapTotal: number;\n heapUsed: number;\n external: number;\n arrayBuffers: number;\n }\n\n interface CpuUsage {\n user: number;\n system: number;\n }\n\n interface ProcessRelease {\n name: string;\n sourceUrl?: string;\n headersUrl?: string;\n libUrl?: string;\n lts?: string;\n }\n\n interface ProcessVersions extends Dict<string> {\n http_parser: string;\n node: string;\n v8: string;\n ares: string;\n uv: string;\n zlib: string;\n modules: string;\n openssl: string;\n }\n\n type Platform = 'aix'\n | 'android'\n | 'darwin'\n | 'freebsd'\n | 'linux'\n | 'openbsd'\n | 'sunos'\n | 'win32'\n | 'cygwin'\n | 'netbsd';\n\n type Signals =\n \"SIGABRT\" | \"SIGALRM\" | \"SIGBUS\" | \"SIGCHLD\" | \"SIGCONT\" | \"SIGFPE\" | \"SIGHUP\" | \"SIGILL\" | \"SIGINT\" | \"SIGIO\" |\n \"SIGIOT\" | \"SIGKILL\" | \"SIGPIPE\" | \"SIGPOLL\" | \"SIGPROF\" | \"SIGPWR\" | \"SIGQUIT\" | \"SIGSEGV\" | \"SIGSTKFLT\" |\n \"SIGSTOP\" | \"SIGSYS\" | \"SIGTERM\" | \"SIGTRAP\" | \"SIGTSTP\" | \"SIGTTIN\" | \"SIGTTOU\" | \"SIGUNUSED\" | \"SIGURG\" |\n \"SIGUSR1\" | \"SIGUSR2\" | \"SIGVTALRM\" | \"SIGWINCH\" | \"SIGXCPU\" | \"SIGXFSZ\" | \"SIGBREAK\" | \"SIGLOST\" | \"SIGINFO\";\n\n type MultipleResolveType = 'resolve' | 'reject';\n\n type BeforeExitListener = (code: number) => void;\n type DisconnectListener = () => void;\n type ExitListener = (code: number) => void;\n type RejectionHandledListener = (promise: Promise<any>) => void;\n type UncaughtExceptionListener = (error: Error) => void;\n type UnhandledRejectionListener = (reason: {} | null | undefined, promise: Promise<any>) => void;\n type WarningListener = (warning: Error) => void;\n type MessageListener = (message: any, sendHandle: any) => void;\n type SignalsListener = (signal: Signals) => void;\n type NewListenerListener = (type: string | symbol, listener: (...args: any[]) => void) => void;\n type RemoveListenerListener = (type: string | symbol, listener: (...args: any[]) => void) => void;\n type MultipleResolveListener = (type: MultipleResolveType, promise: Promise<any>, value: any) => void;\n\n interface Socket extends ReadWriteStream {\n isTTY?: true;\n }\n\n // Alias for compatibility\n interface ProcessEnv extends Dict<string> {}\n\n interface HRTime {\n (time?: [number, number]): [number, number];\n bigint(): bigint;\n }\n\n interface ProcessReport {\n /**\n * Directory where the report is written.\n * working directory of the Node.js process.\n * @default '' indicating that reports are written to the current\n */\n directory: string;\n\n /**\n * Filename where the report is written.\n * The default value is the empty string.\n * @default '' the output filename will be comprised of a timestamp,\n * PID, and sequence number.\n */\n filename: string;\n\n /**\n * Returns a JSON-formatted diagnostic report for the running process.\n * The report's JavaScript stack trace is taken from err, if present.\n */\n getReport(err?: Error): string;\n\n /**\n * If true, a diagnostic report is generated on fatal errors,\n * such as out of memory errors or failed C++ assertions.\n * @default false\n */\n reportOnFatalError: boolean;\n\n /**\n * If true, a diagnostic report is generated when the process\n * receives the signal specified by process.report.signal.\n * @defaul false\n */\n reportOnSignal: boolean;\n\n /**\n * If true, a diagnostic report is generated on uncaught exception.\n * @default false\n */\n reportOnUncaughtException: boolean;\n\n /**\n * The signal used to trigger the creation of a diagnostic report.\n * @default 'SIGUSR2'\n */\n signal: Signals;\n\n /**\n * Writes a diagnostic report to a file. If filename is not provided, the default filename\n * includes the date, time, PID, and a sequence number.\n * The report's JavaScript stack trace is taken from err, if present.\n *\n * @param fileName Name of the file where the report is written.\n * This should be a relative path, that will be appended to the directory specified in\n * `process.report.directory`, or the current working directory of the Node.js process,\n * if unspecified.\n * @param error A custom error used for reporting the JavaScript stack.\n * @return Filename of the generated report.\n */\n writeReport(fileName?: string): string;\n writeReport(error?: Error): string;\n writeReport(fileName?: string, err?: Error): string;\n }\n\n interface ResourceUsage {\n fsRead: number;\n fsWrite: number;\n involuntaryContextSwitches: number;\n ipcReceived: number;\n ipcSent: number;\n majorPageFault: number;\n maxRSS: number;\n minorPageFault: number;\n sharedMemorySize: number;\n signalsCount: number;\n swappedOut: number;\n systemCPUTime: number;\n unsharedDataSize: number;\n unsharedStackSize: number;\n userCPUTime: number;\n voluntaryContextSwitches: number;\n }\n\n interface Process extends EventEmitter {\n /**\n * Can also be a tty.WriteStream, not typed due to limitations.\n */\n stdout: WriteStream & {\n fd: 1;\n };\n /**\n * Can also be a tty.WriteStream, not typed due to limitations.\n */\n stderr: WriteStream & {\n fd: 2;\n };\n stdin: ReadStream & {\n fd: 0;\n };\n openStdin(): Socket;\n argv: string[];\n argv0: string;\n execArgv: string[];\n execPath: string;\n abort(): never;\n chdir(directory: string): void;\n cwd(): string;\n debugPort: number;\n emitWarning(warning: string | Error, name?: string, ctor?: Function): void;\n env: ProcessEnv;\n exit(code?: number): never;\n exitCode?: number;\n getgid(): number;\n setgid(id: number | string): void;\n getuid(): number;\n setuid(id: number | string): void;\n geteuid(): number;\n seteuid(id: number | string): void;\n getegid(): number;\n setegid(id: number | string): void;\n getgroups(): number[];\n setgroups(groups: ReadonlyArray<string | number>): void;\n setUncaughtExceptionCaptureCallback(cb: ((err: Error) => void) | null): void;\n hasUncaughtExceptionCaptureCallback(): boolean;\n version: string;\n versions: ProcessVersions;\n config: {\n target_defaults: {\n cflags: any[];\n default_configuration: string;\n defines: string[];\n include_dirs: string[];\n libraries: string[];\n };\n variables: {\n clang: number;\n host_arch: string;\n node_install_npm: boolean;\n node_install_waf: boolean;\n node_prefix: string;\n node_shared_openssl: boolean;\n node_shared_v8: boolean;\n node_shared_zlib: boolean;\n node_use_dtrace: boolean;\n node_use_etw: boolean;\n node_use_openssl: boolean;\n target_arch: string;\n v8_no_strict_aliasing: number;\n v8_use_snapshot: boolean;\n visibility: string;\n };\n };\n kill(pid: number, signal?: string | number): true;\n pid: number;\n ppid: number;\n title: string;\n arch: string;\n platform: Platform;\n /** @deprecated since v14.0.0 - use `require.main` instead. */\n mainModule?: Module;\n memoryUsage(): MemoryUsage;\n cpuUsage(previousValue?: CpuUsage): CpuUsage;\n nextTick(callback: Function, ...args: any[]): void;\n release: ProcessRelease;\n features: {\n inspector: boolean;\n debug: boolean;\n uv: boolean;\n ipv6: boolean;\n tls_alpn: boolean;\n tls_sni: boolean;\n tls_ocsp: boolean;\n tls: boolean;\n };\n /**\n * @deprecated since v14.0.0 - Calling process.umask() with no argument causes\n * the process-wide umask to be written twice. This introduces a race condition between threads,\n * and is a potential security vulnerability. There is no safe, cross-platform alternative API.\n */\n umask(): number;\n /**\n * Can only be set if not in worker thread.\n */\n umask(mask: string | number): number;\n uptime(): number;\n hrtime: HRTime;\n domain: Domain;\n\n // Worker\n send?(message: any, sendHandle?: any, options?: { swallowErrors?: boolean}, callback?: (error: Error | null) => void): boolean;\n disconnect(): void;\n connected: boolean;\n\n /**\n * The `process.allowedNodeEnvironmentFlags` property is a special,\n * read-only `Set` of flags allowable within the [`NODE_OPTIONS`][]\n * environment variable.\n */\n allowedNodeEnvironmentFlags: ReadonlySet<string>;\n\n /**\n * Only available with `--experimental-report`\n */\n report?: ProcessReport;\n\n resourceUsage(): ResourceUsage;\n\n traceDeprecation: boolean;\n\n /* EventEmitter */\n addListener(event: \"beforeExit\", listener: BeforeExitListener): this;\n addListener(event: \"disconnect\", listener: DisconnectListener): this;\n addListener(event: \"exit\", listener: ExitListener): this;\n addListener(event: \"rejectionHandled\", listener: RejectionHandledListener): this;\n addListener(event: \"uncaughtException\", listener: UncaughtExceptionListener): this;\n addListener(event: \"uncaughtExceptionMonitor\", listener: UncaughtExceptionListener): this;\n addListener(event: \"unhandledRejection\", listener: UnhandledRejectionListener): this;\n addListener(event: \"warning\", listener: WarningListener): this;\n addListener(event: \"message\", listener: MessageListener): this;\n addListener(event: Signals, listener: SignalsListener): this;\n addListener(event: \"newListener\", listener: NewListenerListener): this;\n addListener(event: \"removeListener\", listener: RemoveListenerListener): this;\n addListener(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n\n emit(event: \"beforeExit\", code: number): boolean;\n emit(event: \"disconnect\"): boolean;\n emit(event: \"exit\", code: number): boolean;\n emit(event: \"rejectionHandled\", promise: Promise<any>): boolean;\n emit(event: \"uncaughtException\", error: Error): boolean;\n emit(event: \"uncaughtExceptionMonitor\", error: Error): boolean;\n emit(event: \"unhandledRejection\", reason: any, promise: Promise<any>): boolean;\n emit(event: \"warning\", warning: Error): boolean;\n emit(event: \"message\", message: any, sendHandle: any): this;\n emit(event: Signals, signal: Signals): boolean;\n emit(event: \"newListener\", eventName: string | symbol, listener: (...args: any[]) => void): this;\n emit(event: \"removeListener\", eventName: string, listener: (...args: any[]) => void): this;\n emit(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n\n on(event: \"beforeExit\", listener: BeforeExitListener): this;\n on(event: \"disconnect\", listener: DisconnectListener): this;\n on(event: \"exit\", listener: ExitListener): this;\n on(event: \"rejectionHandled\", listener: RejectionHandledListener): this;\n on(event: \"uncaughtException\", listener: UncaughtExceptionListener): this;\n on(event: \"uncaughtExceptionMonitor\", listener: UncaughtExceptionListener): this;\n on(event: \"unhandledRejection\", listener: UnhandledRejectionListener): this;\n on(event: \"warning\", listener: WarningListener): this;\n on(event: \"message\", listener: MessageListener): this;\n on(event: Signals, listener: SignalsListener): this;\n on(event: \"newListener\", listener: NewListenerListener): this;\n on(event: \"removeListener\", listener: RemoveListenerListener): this;\n on(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n on(event: string | symbol, listener: (...args: any[]) => void): this;\n\n once(event: \"beforeExit\", listener: BeforeExitListener): this;\n once(event: \"disconnect\", listener: DisconnectListener): this;\n once(event: \"exit\", listener: ExitListener): this;\n once(event: \"rejectionHandled\", listener: RejectionHandledListener): this;\n once(event: \"uncaughtException\", listener: UncaughtExceptionListener): this;\n once(event: \"uncaughtExceptionMonitor\", listener: UncaughtExceptionListener): this;\n once(event: \"unhandledRejection\", listener: UnhandledRejectionListener): this;\n once(event: \"warning\", listener: WarningListener): this;\n once(event: \"message\", listener: MessageListener): this;\n once(event: Signals, listener: SignalsListener): this;\n once(event: \"newListener\", listener: NewListenerListener): this;\n once(event: \"removeListener\", listener: RemoveListenerListener): this;\n once(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n\n prependListener(event: \"beforeExit\", listener: BeforeExitListener): this;\n prependListener(event: \"disconnect\", listener: DisconnectListener): this;\n prependListener(event: \"exit\", listener: ExitListener): this;\n prependListener(event: \"rejectionHandled\", listener: RejectionHandledListener): this;\n prependListener(event: \"uncaughtException\", listener: UncaughtExceptionListener): this;\n prependListener(event: \"uncaughtExceptionMonitor\", listener: UncaughtExceptionListener): this;\n prependListener(event: \"unhandledRejection\", listener: UnhandledRejectionListener): this;\n prependListener(event: \"warning\", listener: WarningListener): this;\n prependListener(event: \"message\", listener: MessageListener): this;\n prependListener(event: Signals, listener: SignalsListener): this;\n prependListener(event: \"newListener\", listener: NewListenerListener): this;\n prependListener(event: \"removeListener\", listener: RemoveListenerListener): this;\n prependListener(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n\n prependOnceListener(event: \"beforeExit\", listener: BeforeExitListener): this;\n prependOnceListener(event: \"disconnect\", listener: DisconnectListener): this;\n prependOnceListener(event: \"exit\", listener: ExitListener): this;\n prependOnceListener(event: \"rejectionHandled\", listener: RejectionHandledListener): this;\n prependOnceListener(event: \"uncaughtException\", listener: UncaughtExceptionListener): this;\n prependOnceListener(event: \"uncaughtExceptionMonitor\", listener: UncaughtExceptionListener): this;\n prependOnceListener(event: \"unhandledRejection\", listener: UnhandledRejectionListener): this;\n prependOnceListener(event: \"warning\", listener: WarningListener): this;\n prependOnceListener(event: \"message\", listener: MessageListener): this;\n prependOnceListener(event: Signals, listener: SignalsListener): this;\n prependOnceListener(event: \"newListener\", listener: NewListenerListener): this;\n prependOnceListener(event: \"removeListener\", listener: RemoveListenerListener): this;\n prependOnceListener(event: \"multipleResolves\", listener: MultipleResolveListener): this;\n\n listeners(event: \"beforeExit\"): BeforeExitListener[];\n listeners(event: \"disconnect\"): DisconnectListener[];\n listeners(event: \"exit\"): ExitListener[];\n listeners(event: \"rejectionHandled\"): RejectionHandledListener[];\n listeners(event: \"uncaughtException\"): UncaughtExceptionListener[];\n listeners(event: \"uncaughtExceptionMonitor\"): UncaughtExceptionListener[];\n listeners(event: \"unhandledRejection\"): UnhandledRejectionListener[];\n listeners(event: \"warning\"): WarningListener[];\n listeners(event: \"message\"): MessageListener[];\n listeners(event: Signals): SignalsListener[];\n listeners(event: \"newListener\"): NewListenerListener[];\n listeners(event: \"removeListener\"): RemoveListenerListener[];\n listeners(event: \"multipleResolves\"): MultipleResolveListener[];\n }\n\n interface Global {\n process: Process;\n }\n }\n }\n\n export = process;\n}\n";
10
-
11
- const global = "\ndeclare global {\n /**\n * Read a line from stdin\n */\n function readline(): string;\n\n /**\n * Print a string to stdout\n * @deprecated Use console.log instead\n */\n function print(word: string): void;\n}\n\n// It needs to be a module\nexport {}\n";
12
- const compilerOptions = {
13
- target: monaco.languages.typescript.ScriptTarget.ES2016,
14
- allowNonTsExtensions: true,
15
- moduleResolution: monaco.languages.typescript.ModuleResolutionKind.NodeJs,
16
- module: monaco.languages.typescript.ModuleKind.CommonJS,
17
- noEmit: true,
18
- lib: ['es2020']
19
- };
20
- monaco.languages.typescript.typescriptDefaults.setCompilerOptions(compilerOptions);
21
- monaco.languages.typescript.typescriptDefaults.addExtraLib(global, 'global.d.ts');
22
- monaco.languages.typescript.typescriptDefaults.addExtraLib(typescriptGlobal, 'node/globals.d.ts');
23
- monaco.languages.typescript.typescriptDefaults.addExtraLib(typescriptConsole, 'node/console.d.ts');
24
- monaco.languages.typescript.typescriptDefaults.addExtraLib(typescriptProcess, 'node/process.d.ts');
25
- monaco.languages.typescript.javascriptDefaults.setCompilerOptions(compilerOptions);
26
- monaco.languages.typescript.javascriptDefaults.addExtraLib(global, 'global.d.ts');
27
- monaco.languages.typescript.javascriptDefaults.addExtraLib(typescriptGlobal, 'node/globals.d.ts');
28
- monaco.languages.typescript.javascriptDefaults.addExtraLib(typescriptConsole, 'node/console.d.ts');
29
- monaco.languages.typescript.javascriptDefaults.addExtraLib(typescriptProcess, 'node/process.d.ts');
30
-
31
- const workerLoader = async () => (await import(
32
- /* webpackChunkName: "MonacoTypescriptWorker" */
33
- './ts.worker.js').then(module => module)).default;
34
-
35
- registerWorkerLoader('typescript', workerLoader);
36
- registerWorkerLoader('javascript', workerLoader);
@@ -1,312 +0,0 @@
1
- var Constructor = {
2
- prefix: "ctor",
3
- body: [
4
- "/**",
5
- " *",
6
- " */",
7
- "constructor() {",
8
- "\tsuper();",
9
- "\t$0",
10
- "}"
11
- ],
12
- description: "Constructor"
13
- };
14
- var typescriptreact = {
15
- Constructor: Constructor,
16
- "Class Definition": {
17
- prefix: "class",
18
- body: [
19
- "class ${1:name} {",
20
- "\tconstructor(${2:parameters}) {",
21
- "\t\t$0",
22
- "\t}",
23
- "}"
24
- ],
25
- description: "Class Definition"
26
- },
27
- "Public Method Definition": {
28
- prefix: "public method",
29
- body: [
30
- "/**",
31
- " * ${1:name}",
32
- " */",
33
- "public ${1:name}() {",
34
- "\t$0",
35
- "}"
36
- ],
37
- description: "Public Method Definition"
38
- },
39
- "Private Method Definition": {
40
- prefix: "private method",
41
- body: [
42
- "private ${1:name}() {",
43
- "\t$0",
44
- "}"
45
- ],
46
- description: "Private Method Definition"
47
- },
48
- "Import external module.": {
49
- prefix: "import statement",
50
- body: [
51
- "import { $0 } from \"${1:module}\";"
52
- ],
53
- description: "Import external module."
54
- },
55
- "Property getter": {
56
- prefix: "get",
57
- body: [
58
- "",
59
- "public get ${1:value}() : ${2:string} {",
60
- "\t${3:return $0}",
61
- "}",
62
- ""
63
- ],
64
- description: "Property getter"
65
- },
66
- "Log to the console": {
67
- prefix: "log",
68
- body: [
69
- "console.log($1);",
70
- "$0"
71
- ],
72
- description: "Log to the console"
73
- },
74
- "Log warning to console": {
75
- prefix: "warn",
76
- body: [
77
- "console.warn($1);",
78
- "$0"
79
- ],
80
- description: "Log warning to the console"
81
- },
82
- "Log error to console": {
83
- prefix: "error",
84
- body: [
85
- "console.error($1);",
86
- "$0"
87
- ],
88
- description: "Log error to the console"
89
- },
90
- "Define a full property": {
91
- prefix: "prop",
92
- body: [
93
- "",
94
- "private _${1:value} : ${2:string};",
95
- "public get ${1:value}() : ${2:string} {",
96
- "\treturn this._${1:value};",
97
- "}",
98
- "public set ${1:value}(v : ${2:string}) {",
99
- "\tthis._${1:value} = v;",
100
- "}",
101
- ""
102
- ],
103
- description: "Define a full property"
104
- },
105
- "Triple-slash reference": {
106
- prefix: "ref",
107
- body: [
108
- "/// <reference path=\"$1\" />",
109
- "$0"
110
- ],
111
- description: "Triple-slash reference"
112
- },
113
- "Property setter": {
114
- prefix: "set",
115
- body: [
116
- "",
117
- "public set ${1:value}(v : ${2:string}) {",
118
- "\tthis.$3 = v;",
119
- "}",
120
- ""
121
- ],
122
- description: "Property setter"
123
- },
124
- "Throw Exception": {
125
- prefix: "throw",
126
- body: [
127
- "throw new Error(\"$1\");",
128
- "$0"
129
- ],
130
- description: "Throw Exception"
131
- },
132
- "For Loop": {
133
- prefix: "for",
134
- body: [
135
- "for (let ${1:index} = 0; ${1:index} < ${2:array}.length; ${1:index}++) {",
136
- "\tconst ${3:element} = ${2:array}[${1:index}];",
137
- "\t$TM_SELECTED_TEXT$0",
138
- "}"
139
- ],
140
- description: "For Loop"
141
- },
142
- "For-Each Loop using =>": {
143
- prefix: "foreach =>",
144
- body: [
145
- "${1:array}.forEach(${2:element} => {",
146
- "\t$TM_SELECTED_TEXT$0",
147
- "});"
148
- ],
149
- description: "For-Each Loop using =>"
150
- },
151
- "For-In Loop": {
152
- prefix: "forin",
153
- body: [
154
- "for (const ${1:key} in ${2:object}) {",
155
- "\tif (Object.prototype.hasOwnProperty.call(${2:object}, ${1:key})) {",
156
- "\t\tconst ${3:element} = ${2:object}[${1:key}];",
157
- "\t\t$TM_SELECTED_TEXT$0",
158
- "\t}",
159
- "}"
160
- ],
161
- description: "For-In Loop"
162
- },
163
- "For-Of Loop": {
164
- prefix: "forof",
165
- body: [
166
- "for (const ${1:iterator} of ${2:object}) {",
167
- "\t$TM_SELECTED_TEXT$0",
168
- "}"
169
- ],
170
- description: "For-Of Loop"
171
- },
172
- "For-Await-Of Loop": {
173
- prefix: "forawaitof",
174
- body: [
175
- "for await (const ${1:iterator} of ${2:object}) {",
176
- "\t$TM_SELECTED_TEXT$0",
177
- "}"
178
- ],
179
- description: "For-Await-Of Loop"
180
- },
181
- "Function Statement": {
182
- prefix: "function",
183
- body: [
184
- "function ${1:name}(${2:params}:${3:type}) {",
185
- "\t$TM_SELECTED_TEXT$0",
186
- "}"
187
- ],
188
- description: "Function Statement"
189
- },
190
- "If Statement": {
191
- prefix: "if",
192
- body: [
193
- "if (${1:condition}) {",
194
- "\t$TM_SELECTED_TEXT$0",
195
- "}"
196
- ],
197
- description: "If Statement"
198
- },
199
- "If-Else Statement": {
200
- prefix: "ifelse",
201
- body: [
202
- "if (${1:condition}) {",
203
- "\t$TM_SELECTED_TEXT$0",
204
- "} else {",
205
- "\t",
206
- "}"
207
- ],
208
- description: "If-Else Statement"
209
- },
210
- "New Statement": {
211
- prefix: "new",
212
- body: [
213
- "const ${1:name} = new ${2:type}(${3:arguments});$0"
214
- ],
215
- description: "New Statement"
216
- },
217
- "Switch Statement": {
218
- prefix: "switch",
219
- body: [
220
- "switch (${1:key}) {",
221
- "\tcase ${2:value}:",
222
- "\t\t$0",
223
- "\t\tbreak;",
224
- "",
225
- "\tdefault:",
226
- "\t\tbreak;",
227
- "}"
228
- ],
229
- description: "Switch Statement"
230
- },
231
- "While Statement": {
232
- prefix: "while",
233
- body: [
234
- "while (${1:condition}) {",
235
- "\t$TM_SELECTED_TEXT$0",
236
- "}"
237
- ],
238
- description: "While Statement"
239
- },
240
- "Do-While Statement": {
241
- prefix: "dowhile",
242
- body: [
243
- "do {",
244
- "\t$TM_SELECTED_TEXT$0",
245
- "} while (${1:condition});"
246
- ],
247
- description: "Do-While Statement"
248
- },
249
- "Try-Catch Statement": {
250
- prefix: "trycatch",
251
- body: [
252
- "try {",
253
- "\t$TM_SELECTED_TEXT$0",
254
- "} catch (${1:error}) {",
255
- "\t",
256
- "}"
257
- ],
258
- description: "Try-Catch Statement"
259
- },
260
- "Set Timeout Function": {
261
- prefix: "settimeout",
262
- body: [
263
- "setTimeout(() => {",
264
- "\t$TM_SELECTED_TEXT$0",
265
- "}, ${1:timeout});"
266
- ],
267
- description: "Set Timeout Function"
268
- },
269
- "Region Start": {
270
- prefix: "#region",
271
- body: [
272
- "//#region $0"
273
- ],
274
- description: "Folding Region Start"
275
- },
276
- "Region End": {
277
- prefix: "#endregion",
278
- body: [
279
- "//#endregion"
280
- ],
281
- description: "Folding Region End"
282
- },
283
- "new Promise": {
284
- prefix: "newpromise",
285
- body: [
286
- "new Promise<${1:void}>((resolve, reject) => {",
287
- "\t$TM_SELECTED_TEXT$0",
288
- "})"
289
- ],
290
- description: "Create a new Promise"
291
- },
292
- "Async Function Statement": {
293
- prefix: "async function",
294
- body: [
295
- "async function ${1:name}(${2:params}:${3:type}) {",
296
- "\t$TM_SELECTED_TEXT$0",
297
- "}"
298
- ],
299
- description: "Async Function Statement"
300
- },
301
- "Async Function Expression": {
302
- prefix: "async arrow function",
303
- body: [
304
- "async (${1:params}:${2:type}) => {",
305
- "\t$TM_SELECTED_TEXT$0",
306
- "}"
307
- ],
308
- description: "Async Function Expression"
309
- }
310
- };
311
-
312
- export { Constructor, typescriptreact as default };
package/dist/vb2.js DELETED
@@ -1,88 +0,0 @@
1
- var vb = {
2
- "For Next Loop": {
3
- prefix: "for",
4
- body: [
5
- "For ${1:index} As ${2:ObjectType} = ${3:lower} To ${4:Upper}",
6
- "\t$0",
7
- "Next ${1:index}"
8
- ],
9
- description: "For Next Loop"
10
- },
11
- "For Each...Next": {
12
- prefix: "fore",
13
- body: [
14
- "For Each ${1:Variable} As ${2:ObjectType} In ${3:Collection}",
15
- "\t$0",
16
- "Next"
17
- ],
18
- description: "For Each...Next"
19
- },
20
- "For i...Next i": {
21
- prefix: "fori",
22
- body: [
23
- "For i As ${1:Integer} = ${2:Lower} To ${3:Upper}",
24
- "\t$0",
25
- "Next i"
26
- ],
27
- description: "For i...Next i"
28
- },
29
- "For j...Next j": {
30
- prefix: "forj",
31
- body: [
32
- "For j As ${1:Integer} = ${2:Lower} To ${3:Upper}",
33
- "\t$0",
34
- "Next j"
35
- ],
36
- description: "For j...Next j"
37
- },
38
- "Public Function...": {
39
- prefix: "pf",
40
- body: [
41
- "Public Function ${1:FunctionName}(${2:ParameterList}) As ${3:ReturnType}",
42
- "\tTry",
43
- "\t\t$0",
44
- "\tCatch ex As Exception",
45
- "\tEnd Try",
46
- "\tReturn ${3:ReturnValue}",
47
- "End Function"
48
- ],
49
- description: "Public Function..."
50
- },
51
- "Public Sub ...": {
52
- prefix: "ps",
53
- body: [
54
- "Public Sub ${1:ProcedureName}(${2:ParameterList})",
55
- "\tTry",
56
- "\t\t$0",
57
- "\tCatch ex As Exception",
58
- "\tEnd Try",
59
- "End Sub"
60
- ],
61
- description: "Public Sub ..."
62
- },
63
- "While ... End While": {
64
- prefix: "while",
65
- body: [
66
- "While ${1:Boolean}",
67
- "\t$0",
68
- "End While"
69
- ],
70
- description: "While ... End While"
71
- },
72
- "Region Start": {
73
- prefix: "#Region",
74
- body: [
75
- "#Region $0"
76
- ],
77
- description: "Folding Region Start"
78
- },
79
- "Region End": {
80
- prefix: "#End Region",
81
- body: [
82
- "#End Region"
83
- ],
84
- description: "Folding Region End"
85
- }
86
- };
87
-
88
- export { vb as default };