Turbo loader item options type too strict
Open
Nobody has claimed this yet.
TypeScript
- Dominant language
- JavaScript
- Stars
- 142k
- Forks
- 32.4k
- Avg merge
- 2d 14h
- Merged PRs (30d)
- 351
Description
Link to the code that reproduces this issue
https://github.com/Netail/repro-next-typescript-next-config
To Reproduce
- Install dependencies;
yarn install - Inspect
next.config.ts - Svgr options clash with turbo options type
Current vs. Expected behavior
The turbo loader options type are a bit too strict compared to what's allowed by e.g. the SVGR plugin options
Provide environment information
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.1.0: Thu Oct 10 21:03:15 PDT 2024; root:xnu-11215.41.3~2/RELEASE_ARM64_T6000
Available memory (MB): 32768
Available CPU cores: 10
Binaries:
Node: 22.11.0
npm: 10.9.0
Yarn: 1.22.22
pnpm: 9.6.0
Relevant Packages:
next: 15.1.3 // Latest available version is detected (15.1.3).
eslint-config-next: N/A
react: 19.0.0
react-dom: 19.0.0
typescript: 5.7.2
Next.js Config:
output: N/A
Which area(s) are affected? (Select all that apply)
TypeScript
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Run yarn install in the linked reproduction and inspect next.config.ts to isolate the clash between SVGR options and the turbo loader options type. Trace the corresponding Next.js TypeScript definitions, then verify that the reproduction config type-checks while retaining the supported turbo options.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- nextjs, typescript
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100