jstestrunner

How to use Mocha and Jest with TypeScript without conflicts?

时光总嘲笑我的痴心妄想 提交于 2021-01-21 07:04:50
问题 I'm trying to install Mocha and Jest with types on one project. We use strict typecheck, so I get errors related to conflicting globals type. I've tried to create ambiguous module declaration, defining only Mocha in types at tsconfig . I've been trying to remove Jest's declaration - but that would partially help. Disabling strict typecheck or lib check is not an option. I expected to work it properly, but instead got the next errors. node_modules/@types/jest/index.d.ts(29,13): error TS2403:

How to use Mocha and Jest with TypeScript without conflicts?

筅森魡賤 提交于 2021-01-21 07:03:11
问题 I'm trying to install Mocha and Jest with types on one project. We use strict typecheck, so I get errors related to conflicting globals type. I've tried to create ambiguous module declaration, defining only Mocha in types at tsconfig . I've been trying to remove Jest's declaration - but that would partially help. Disabling strict typecheck or lib check is not an option. I expected to work it properly, but instead got the next errors. node_modules/@types/jest/index.d.ts(29,13): error TS2403: