sannajammeh / trpc-swr

tRPC-ified SWR hooks
https://trpc-swr.vercel.app
MIT License
209 stars 5 forks source link

Support for type definition when using suspense #48

Closed sskmy1024y closed 10 months ago

sskmy1024y commented 11 months ago
before after
image image

trpc-swr is a great library, but there is one problem. That is that type completion does not work properly when using suspense mode to retrieve data.

We have created a PR that fixes this issue. We hope it will be a better library!

changeset-bot[bot] commented 11 months ago

⚠️ No Changeset found

Latest commit: b2283bb1182576fcd69d1c895eee7fc9835f8ff7

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

vercel[bot] commented 11 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment | Name | Status | Preview | Comments | Updated (UTC) | | :--- | :----- | :------ | :------- | :------ | | **trpc-swr** | ⬜️ Ignored ([Inspect](https://vercel.com/sannajammeh/trpc-swr/BMM84szUxPHJCY9gt2xqKZMdiDGY)) | [Visit Preview](https://trpc-swr-git-fork-sskmy1024y-feat-type-suppo-5dd5e5-sannajammeh.vercel.app) | | Oct 6, 2023 1:20pm |
sannajammeh commented 10 months ago

Apologies for the wait, Ill be looking at this tonight!

sskmy1024y commented 10 months ago

@sannajammeh Thank you. We are looking forward to your approve.

sannajammeh commented 10 months ago

@sskmy1024y Hey, nice work! PR works excellent. I added a test case for the suspense types. Could you give me push permissions to your fork?

sskmy1024y commented 10 months ago

@sannajammeh Thank you! You have been added to collaborator. Please check it out!