Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VScode unable to find type definitions for jest. #743

Closed
ydennisy opened this issue Jun 9, 2020 · 3 comments
Closed

VScode unable to find type definitions for jest. #743

ydennisy opened this issue Jun 9, 2020 · 3 comments
Labels
problem: stale Issue has not been responded to in some time

Comments

@ydennisy
Copy link

ydennisy commented Jun 9, 2020

Current Behavior

Everything is working as expected, but VSCode cannot find the type definitions for jest, I am pretty much using an unchanged init of the library:

image

I have tried adding the types manually to the package.json with no luck.

Expected behavior

No errors to be shown.

Suggested solution(s)

Additional context

Your environment

Software Version(s)
TSDX 0.13.2
TypeScript 3.9.5
Browser NA
npm/Yarn 1.6.0
Node 12
Operating System Mac
@agilgur5
Copy link
Collaborator

agilgur5 commented Jun 12, 2020

Might be a regression from #672 since @types/jest was removed from the templates and added as a direct TSDX dependency (maybe that's why it was like that in the first place but there were no comments on it 😕 ).

But since you said you installed the types yourself and it still didn't work sounds like a possible duplicate of #696 .

I have tried adding the types manually to the package.json with no luck.

Did you npm install -D @types/jest? Or just added to package.json?

@agilgur5 agilgur5 added the problem: stale Issue has not been responded to in some time label Jun 19, 2020
@nikhilag
Copy link

@agilgur5 I tried yarn add @types/jest --dev but it didn't work for me. I am still getting the following error in VSCode:-

Cannot find name 'describe'. Do you need to install type definitions for a test runner? Try npm i --save-dev @types/jest or npm i --save-dev @types/mocha.ts(2582)

Can we reopen this issue because it seems anyone would encounter this during setup itself?

@mserikov

This comment was marked as spam.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
problem: stale Issue has not been responded to in some time
Projects
None yet
Development

No branches or pull requests

4 participants