toss / suspensive

Packages to use React Suspense easily (one of Tanstack Query community resources)
https://suspensive.org
MIT License
417 stars 37 forks source link

docs(suspensive.org): add sandpack examples to SuspenseQuery, SuspenseQueries, and SuspenseInfiniteQuery #1016

Closed kangju2000 closed 1 week ago

kangju2000 commented 1 week ago

Overview

Add sandpack examples to SuspenseQuery, SuspenseQueries, and SuspenseInfiniteQuery.

I found a type error that occurs when passing the return value of queryOptions as a property to SuspenseInfiniteQuery. Since Sandpack doesn't catch type errors, I'm submitting this PR while creating a separate issue for the type problem. (Issue: https://github.com/toss/suspensive/issues/1015)

PR Checklist

  1. I read the Contributing Guide
  2. I added documents and tests.
changeset-bot[bot] commented 1 week ago

⚠️ No Changeset found

Latest commit: 0ce5061914682cef580514413abd7e5e222bfd68

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 1 week ago

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

Name Status Preview Comments Updated (UTC)
suspensive.org ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 30, 2024 9:12pm
v1.suspensive.org ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 30, 2024 9:12pm
visualization.suspensive.org ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 30, 2024 9:12pm
codecov-commenter commented 1 week ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 87.33%. Comparing base (fce0d25) to head (0ce5061).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/toss/suspensive/pull/1016/graphs/tree.svg?width=650&height=150&src=pr&token=5PopssACmx&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss)](https://app.codecov.io/gh/toss/suspensive/pull/1016?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) ```diff @@ Coverage Diff @@ ## main #1016 +/- ## ======================================= Coverage 87.33% 87.33% ======================================= Files 38 38 Lines 450 450 Branches 99 99 ======================================= Hits 393 393 Misses 54 54 Partials 3 3 ``` | [Components](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=components&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | Coverage Δ | | |---|---|---| | [@suspensive/react](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `97.03% <ø> (ø)` | | | [@suspensive/react-query](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `∅ <ø> (∅)` | | | [@suspensive/react-query-4](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `0.00% <ø> (ø)` | | | [@suspensive/react-query-5](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `0.00% <ø> (ø)` | | | [@suspensive/react-await](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `100.00% <ø> (ø)` | | | [@suspensive/react-image](https://app.codecov.io/gh/toss/suspensive/pull/1016/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toss) | `80.39% <ø> (ø)` | |
codspeed-hq[bot] commented 1 week ago

CodSpeed Performance Report

Merging #1016 will create unknown performance changes

Comparing add-suspense-query-examples (0ce5061) with main (fce0d25)

Summary

:warning: No benchmarks were detected in both the base of the PR and the PR.

manudeli commented 1 week ago

I found a type error that occurs when passing the return value of queryOptions as a property to SuspenseInfiniteQuery. Since Sandpack doesn't catch type errors, I'm submitting this PR while creating a separate issue for the type problem. (Issue: https://github.com/toss/suspensive/issues/1015)

https://tanstack.com/query/v5/docs/framework/react/reference/infiniteQueryOptions

👀🦅 In my opinion, We should make infiniteQueryOptions! Let's make it later