Type instantiation is excessively deep and possibly infinite - With Simple Reproduction
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 6.7k
- Forks
- 682
- Avg merge
- 5d 18h
- Merged PRs (30d)
- 7
Description
Describe the bug
This is another instance of the TS error. The reproduction is based on the solid example with one new field.
That JsonData type is taken from here
Your minimal, reproducible example
https://codesandbox.io/p/devbox/quizzical-snyder-w4wf5q?file=%2Fsrc%2Findex.tsx
Steps to reproduce
- Open the reproduction
- See the error
Expected behavior
I would expect the form to handle this recursive type.
How often does this bug happen?
Every time
Screenshots or Videos
No response
Platform
TanStack Form adapter
solid-form
TanStack Form version
1.9.0
TypeScript version
5.8.2
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
Open the linked CodeSandbox reproduction and inspect src/index.tsx, the only file identified in the report. Reproduce the error with TypeScript 5.8.2 and the solid-form adapter; done means the recursive JsonData type is accepted without the “Type instantiation is excessively deep” error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100