chromeless
chromeless copied to clipboard
error TS2420: Class 'Chromeless<T>' incorrectly implements interface 'Promise<T>'
Chromeless 1.5.0 under TypeScript 1.7.2 imported as
import { Chromeless } from "chromeless";
// or
// import Chromeless from "chromeless";
returns the following error when the compiler attempts to resolve all dependencies:
node_modules/chromeless/dist/src/api.d.ts(2,22): error TS2420: Class 'Chromeless<T>' incorrectly implements interface 'Promise<T>'.
Property 'finally' is missing in type 'Chromeless<T>'.
My compiler options (tsconfig.json) are as follows:
{
"compilerOptions": {
"target": "es5",
"lib": ["dom", "esnext"],
"module": "commonjs",
"declaration": true,
"moduleResolution": "node",
"sourceMap": true
}
}
Experiencing the same problem - my workaround is to remove esnext from libs, as Promise.finally is part of esnext.