Migrate whitespace tslint rule
This commit is contained in:
@@ -93,7 +93,7 @@ export abstract class BaseRenderLayer implements IRenderLayer {
|
||||
const oldCanvas = this._canvas;
|
||||
this._alpha = alpha;
|
||||
// Cloning preserves properties
|
||||
this._canvas = <HTMLCanvasElement>this._canvas.cloneNode();
|
||||
this._canvas = this._canvas.cloneNode() as HTMLCanvasElement;
|
||||
this._initCanvas();
|
||||
this._container.replaceChild(this._canvas, oldCanvas);
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ export class InstantiationService implements IInstantiationService {
|
||||
return this._services.get(id);
|
||||
}
|
||||
|
||||
public createInstance<T>(ctor: any, ...args: any[]): any {
|
||||
public createInstance<T>(ctor: any, ...args: any[]): T {
|
||||
const serviceDependencies = getServiceDependencies(ctor).sort((a, b) => a.index - b.index);
|
||||
|
||||
const serviceArgs: any[] = [];
|
||||
@@ -76,6 +76,6 @@ export class InstantiationService implements IInstantiationService {
|
||||
}
|
||||
|
||||
// now create the instance
|
||||
return <T>new ctor(...[...args, ...serviceArgs]);
|
||||
return new ctor(...[...args, ...serviceArgs]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ export function createDecorator<T>(id: string): IServiceIdentifier<T> {
|
||||
return serviceRegistry.get(id)!;
|
||||
}
|
||||
|
||||
const decorator = <any>function (target: Function, key: string, index: number): any {
|
||||
const decorator: any = function (target: Function, key: string, index: number): any {
|
||||
if (arguments.length !== 3) {
|
||||
throw new Error('@IServiceName-decorator can only be used to decorate a parameter');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user