Skip to content

docs(preact-query): add 'Suspense' and 'Testing' guides - #11377

Merged
sukvvon merged 1 commit into
TanStack:mainfrom
S-jooyoung:docs/preact-suspense-testing-guides
Sep 4, 2026
Merged

docs(preact-query): add 'Suspense' and 'Testing' guides#11377
sukvvon merged 1 commit into
TanStack:mainfrom
S-jooyoung:docs/preact-suspense-testing-guides

Conversation

@S-jooyoung

@S-jooyoung S-jooyoung commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

🎯 Changes

Adds the Suspense and Testing guides to the Preact docs. Both pages exist for React but had no Preact counterpart, even though @tanstack/preact-query ships useSuspenseQuery / useSuspenseInfiniteQuery / useSuspenseQueries and QueryErrorResetBoundary, and its reference docs already link to them.

Changes

  • docs/framework/preact/guides/suspense.md, docs/framework/preact/guides/testing.md: new pages following the existing Preact docs convention (ref: to the React guide + replace: + section overrides), so the shared prose stays in one place.
  • docs/framework/react/guides/suspense.md, docs/framework/react/guides/testing.md: add [//]: # 'Section' markers around the React-specific parts so they can be overridden. No wording changes to the React pages.
  • Preact overrides:
    • Suspense: Suspense from preact/compat, an ErrorBoundary built on useErrorBoundary instead of react-error-boundary, drops the startTransition note and the Next.js streaming section.
    • Testing: @testing-library/preact (renderHook + waitFor) instead of the React 17/18 testing-library notes.
  • docs/config.json: register both pages under the Preact guides, in the same position as the React menu.

Test plan

  • pnpm nx run-many --target=test:docs (scripts/verify-links.ts) passes.
  • pnpm prettier --check on the changed files.

✅ Checklist

  • I have followed the steps in the Contributing guide.
  • I have tested code changes locally with pnpm run test:pr, or these tests do not apply to this pull request.
  • I fully understand the code in this pull request, including any code generated with AI assistance.

🚀 Release Impact

  • This change affects published code, and I have generated a changeset.
  • This change is docs/CI/dev-only (no release).

@coderabbitai

coderabbitai Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Team

Run ID: acf8df26-a8ef-4c16-bd63-a93daa4e87f1

📥 Commits

Reviewing files that changed from the base of the PR and between fe77cdc and 0e69e48.

📒 Files selected for processing (5)
  • docs/config.json
  • docs/framework/preact/guides/suspense.md
  • docs/framework/preact/guides/testing.md
  • docs/framework/react/guides/suspense.md
  • docs/framework/react/guides/testing.md

Included review availability: Your plan provides up to 10 included reviews per hour; 7 remain after this review.


📝 Walkthrough

Walkthrough

Adds Preact Query Suspense and testing documentation, exposes both guides in navigation, and adds section markers to related React guides.

Changes

Preact documentation guides

Layer / File(s) Summary
React guide extraction markers
docs/framework/react/guides/suspense.md, docs/framework/react/guides/testing.md
Adds comment markers around reusable sections in the React Suspense and testing guides.
Preact Suspense and testing guides
docs/framework/preact/guides/suspense.md, docs/framework/preact/guides/testing.md
Adds Preact-specific Suspense documentation and testing guidance for custom hooks with @testing-library/preact.
Preact guide navigation
docs/config.json
Adds Suspense and Testing entries to the Preact Guides & Concepts navigation.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to 0e69e

This documentation-only change adds Preact Suspense and testing guides and navigation without affecting published runtime code; no actionable merge-blocking risk remains.

Suggested reviewers: tkdodo, sukvvon

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description check ✅ Passed The description follows the repository template. It explains the changes and motivation, lists the implementation details, documents the test plan, completes the checklist, and correctly identifies th…
Title check ✅ Passed The title clearly and concisely identifies the primary change: adding Suspense and Testing guides to the Preact Query documentation.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

The Preact docs had no counterpart for the React "Suspense" and
"Testing" guides even though `@tanstack/preact-query` ships the
suspense hooks and `QueryErrorResetBoundary`.

Follow the existing Preact docs convention: reference the React guide
via `ref:` + `replace:` and override only the React-specific sections
(`preact/compat` Suspense, an error boundary built on `useErrorBoundary`,
`@testing-library/preact`). The React guides only gain the section
markers needed for the overrides; their wording is unchanged.
@S-jooyoung
S-jooyoung force-pushed the docs/preact-suspense-testing-guides branch from 0e69e48 to 42e53eb Compare September 3, 2026 06:03
@nx-cloud

nx-cloud Bot commented Sep 4, 2026

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit 42e53eb

Command Status Duration Result
nx affected --targets=test:sherif,test:knip,tes... ✅ Succeeded 2m 21s View ↗

☁️ Nx Cloud last updated this comment at 2026-09-04 05:50:30 UTC

@pkg-pr-new

pkg-pr-new Bot commented Sep 4, 2026

Copy link
Copy Markdown
More templates

@tanstack/angular-query-experimental

npm i https://pkg.pr.new/@tanstack/angular-query-experimental@11377

@tanstack/eslint-plugin-query

npm i https://pkg.pr.new/@tanstack/eslint-plugin-query@11377

@tanstack/lit-query

npm i https://pkg.pr.new/@tanstack/lit-query@11377

@tanstack/preact-query

npm i https://pkg.pr.new/@tanstack/preact-query@11377

@tanstack/preact-query-devtools

npm i https://pkg.pr.new/@tanstack/preact-query-devtools@11377

@tanstack/preact-query-persist-client

npm i https://pkg.pr.new/@tanstack/preact-query-persist-client@11377

@tanstack/query-async-storage-persister

npm i https://pkg.pr.new/@tanstack/query-async-storage-persister@11377

@tanstack/query-broadcast-client-experimental

npm i https://pkg.pr.new/@tanstack/query-broadcast-client-experimental@11377

@tanstack/query-core

npm i https://pkg.pr.new/@tanstack/query-core@11377

@tanstack/query-devtools

npm i https://pkg.pr.new/@tanstack/query-devtools@11377

@tanstack/query-persist-client-core

npm i https://pkg.pr.new/@tanstack/query-persist-client-core@11377

@tanstack/query-sync-storage-persister

npm i https://pkg.pr.new/@tanstack/query-sync-storage-persister@11377

@tanstack/react-query

npm i https://pkg.pr.new/@tanstack/react-query@11377

@tanstack/react-query-devtools

npm i https://pkg.pr.new/@tanstack/react-query-devtools@11377

@tanstack/react-query-next-experimental

npm i https://pkg.pr.new/@tanstack/react-query-next-experimental@11377

@tanstack/react-query-persist-client

npm i https://pkg.pr.new/@tanstack/react-query-persist-client@11377

@tanstack/solid-query

npm i https://pkg.pr.new/@tanstack/solid-query@11377

@tanstack/solid-query-devtools

npm i https://pkg.pr.new/@tanstack/solid-query-devtools@11377

@tanstack/solid-query-persist-client

npm i https://pkg.pr.new/@tanstack/solid-query-persist-client@11377

@tanstack/svelte-query

npm i https://pkg.pr.new/@tanstack/svelte-query@11377

@tanstack/svelte-query-devtools

npm i https://pkg.pr.new/@tanstack/svelte-query-devtools@11377

@tanstack/svelte-query-persist-client

npm i https://pkg.pr.new/@tanstack/svelte-query-persist-client@11377

@tanstack/vue-query

npm i https://pkg.pr.new/@tanstack/vue-query@11377

@tanstack/vue-query-devtools

npm i https://pkg.pr.new/@tanstack/vue-query-devtools@11377

commit: 42e53eb

@sukvvon sukvvon changed the title docs(preact-query): add Suspense and Testing guides docs(preact-query): add 'Suspense' and 'Testing' guides Sep 4, 2026
@sukvvon
sukvvon merged commit ec3f992 into TanStack:main Sep 4, 2026
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants