ISISNeutronMuon / ISISNeutronMuon/isisneutronmuon.github.io
Upgrade Typescript to 7 when ts-jest and NextJS properly support them
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 1
- Avg merge
- 13h 43m
- Merged PRs (30d)
- 8
Description
Upgrading to Typescript 7 causes (#43)
```bash
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: ts-jest@29.4.12
npm error Found: typescript@7.0.2
npm error node_modules/typescript
npm error typescript@"7.0.2" from the root project
npm error peerOptional typescript@">=3.3.1" from eslint-config-next@16.2.12
npm error node_modules/eslint-config-next
npm error dev eslint-config-next@"^16.2.12" from the root project
npm error 2 more (ts-api-utils, ts-node)
npm error
npm error Could not resolve dependency:
npm error peer typescript@">=4.3 <7" from ts-jest@29.4.12
npm error node_modules/ts-jest
npm error dev ts-jest@"^29.4.12" from the root project
npm error
npm error Conflicting peer dependency: typescript@6.0.3
npm error node_modules/typescript
npm error peer typescript@">=4.3 <7" from ts-jest@29.4.12
npm error node_modules/ts-jest
npm error dev ts-jest@"^29.4.12" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution.
```
`ts-jest` has a workaround: https://kulshekhar.github.io/ts-jest/docs/next/guides/typescript-7 but this then causes a problem with NextJS as discussed in https://github.com/vercel/next.js/discussions/95633. The fix suggested does not work.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the npm dependency-resolution error, then read the linked ts-jest TypeScript 7 workaround and the referenced Next.js discussion. Done means TypeScript 7, ts-jest, and Next.js can be installed together without an unsupported workaround and the site’s existing checks still pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- nextjs, typescript
- Domain
- build-system, testing, web-dev
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100