Remove obsolete @ts-ignore

This commit is contained in:
Ingvar Stepanyan
2020-09-28 21:50:11 +01:00
committed by Ingvar Stepanyan
parent a9d3bd71b5
commit 8c5c97e106
2 changed files with 1 additions and 4 deletions

View File

@@ -1,4 +1,3 @@
// @ts-ignore
import optimiser from '../../../codecs/oxipng';
import { EncodeOptions } from './encoder-meta';

View File

@@ -62,12 +62,10 @@ export default class Processor {
if (!this._worker && needsWorker) {
// worker-loader does magic here.
// @ts-ignore - Typescript doesn't know about the 2nd param to new Worker, and the
// definition can't be overwritten.
this._worker = new Worker(
'./processor-worker',
{ name: 'processor-worker', type: 'module' },
) as Worker;
);
// Need to do some TypeScript trickery to make the type match.
this._workerApi = proxy(this._worker) as any as ProcessorWorkerApi;
}