mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-20 00:28:52 +01:00
Use ts-go for building our extensions
Also reverts to use experimental decorators due to stage 3 decorators not being supported yet https://github.com/microsoft/typescript-go/issues/2354 The skipLib check is needed to work around some jsdom types issues
This commit is contained in:
@@ -9,14 +9,14 @@ import { ApiRepository, ApiImpl } from './api1';
|
||||
import { Event, EventEmitter } from 'vscode';
|
||||
import { CloneManager } from '../cloneManager';
|
||||
|
||||
function deprecated(original: unknown, context: ClassMemberDecoratorContext) {
|
||||
if (typeof original !== 'function' || context.kind !== 'method') {
|
||||
function deprecated(_target: unknown, key: string | symbol, descriptor: PropertyDescriptor): void {
|
||||
if (typeof descriptor.value !== 'function') {
|
||||
throw new Error('not supported');
|
||||
}
|
||||
|
||||
const key = context.name.toString();
|
||||
return function (this: unknown, ...args: unknown[]) {
|
||||
console.warn(`Git extension API method '${key}' is deprecated.`);
|
||||
const original = descriptor.value;
|
||||
descriptor.value = function (this: unknown, ...args: unknown[]) {
|
||||
console.warn(`Git extension API method '${String(key)}' is deprecated.`);
|
||||
return original.apply(this, args);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user