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

bug: Type inference not working for streams #6407

Open
1 task
benhylak opened this issue Jan 22, 2025 · 2 comments
Open
1 task

bug: Type inference not working for streams #6407

benhylak opened this issue Jan 22, 2025 · 2 comments
Labels

Comments

@benhylak
Copy link

Provide environment information

https://trpc.io/?try=minimal#try-it-out

Describe the bug

Image

https://trpc.io/?try=minimal#try-it-out

Even in the minimal example, type inference is not working for output of async generators.

In the documentation for HTTP Batch Stream Link, it seems like type inference for async generators should still work
Image

Link to reproduction

https://trpc.io/?try=minimal#try-it-out

To reproduce

open up https://trpc.io/?try=minimal#try-it-out

hover over the type on the output of examples.iterable

notice it is any type

Additional information

No response

👨‍👧‍👦 Contributing

  • 🙋‍♂️ Yes, I'd be down to file a PR fixing this bug!
@KATT
Copy link
Member

KATT commented Jan 22, 2025

Yeah, it's because stackblitz is using a version of ts than what we require

@KATT KATT added 📚 documentation / examples Improvements or additions to documentation 👻 invalid Invalid bug report and removed 🐛 bug: unconfirmed labels Jan 22, 2025
@KATT
Copy link
Member

KATT commented Jan 25, 2025

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

No branches or pull requests

2 participants