Migrate whitespace tslint rule

This commit is contained in:
Daniel Imms
2020-03-28 07:34:49 -07:00
parent 2e9b4779c9
commit bbd83b9dba
9 changed files with 19 additions and 16 deletions
+1 -1
View File
@@ -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);
+2 -2
View File
@@ -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]);
}
}
+1 -1
View File
@@ -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');
}