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

Missing types for 'ts-jest/presets' #2325

Closed
josh-hemphill opened this issue Feb 5, 2021 · 3 comments · Fixed by #2337
Closed

Missing types for 'ts-jest/presets' #2325

josh-hemphill opened this issue Feb 5, 2021 · 3 comments · Fixed by #2337

Comments

@josh-hemphill
Copy link

josh-hemphill commented Feb 5, 2021

🐛 Bug Report

When using Jest in full TS mode (jest.config.ts), imports from 'ts-jest/presets' have no type information.
And documentation about useESM is incorrect.

To Reproduce

Steps to reproduce the behavior:
Create a project with a jest.config.ts file and attempt to set up with ts-jest.

Expected behavior

Type information about presets to to be detected and included.

envinfo

System:
    OS: Win10
    Node version: v14.15.4

Npm packages:
    jest: 26.6.3
    ts-jest: 26.5.0
    typescript: 4.1.3
    babel(optional):
@josh-hemphill josh-hemphill added Bug Report Needs Repo Need a minimium repository to reproduce the problem Needs Triage labels Feb 5, 2021
@ahnpnl
Copy link
Collaborator

ahnpnl commented Feb 5, 2021

Indeed we didn’t ship type definition for presets

useESM is only available under next tag :) The documentation for 26.5 was wrong about that option.

@ahnpnl ahnpnl added Documentation 📖 Enhancement ✨ and removed Bug Report Needs Repo Need a minimium repository to reproduce the problem Needs Triage labels Feb 5, 2021
@josh-hemphill josh-hemphill changed the title Missing types for 'ts-jest/presets' and ts-jest global config Missing types for 'ts-jest/presets' Feb 5, 2021
@ahnpnl
Copy link
Collaborator

ahnpnl commented Feb 9, 2021

you can try 26.5.1 which includes all the things you mentioned above, documentation was also updated.

@josh-hemphill
Copy link
Author

It it all seems to get detected properly. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants