Skip to content

docs(angular): fix QueryClient field in paginated guide#10147

Open
pavan-sh wants to merge 1 commit intoTanStack:mainfrom
pavan-sh:docs/angular-paginated-queryclient-fix
Open

docs(angular): fix QueryClient field in paginated guide#10147
pavan-sh wants to merge 1 commit intoTanStack:mainfrom
pavan-sh:docs/angular-paginated-queryclient-fix

Conversation

@pavan-sh
Copy link
Contributor

@pavan-sh pavan-sh commented Feb 18, 2026

🎯 Changes

this.#queryClient... (with #), which in TS/JS means a private class field. The declaration queryClient = inject(QueryClient) creates a public field named queryClient, so this.#queryClient would be undefined and the snippet breaks.

So I changed the declaration to match what the code is actually calling:

• from: queryClient = inject(QueryClient)
• to: #queryClient = inject(QueryClient)

✅ Checklist

  • [] I have followed the steps in the Contributing guide.
  • [] I have tested this code locally with pnpm run test:pr.

🚀 Release Impact

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

Summary by CodeRabbit

  • Documentation
    • Updated code examples in the paginated queries guide to follow best practices for property visibility.

@changeset-bot
Copy link

changeset-bot bot commented Feb 18, 2026

⚠️ No Changeset found

Latest commit: 159d1dc

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

@github-actions github-actions bot added the documentation Improvements or additions to documentation label Feb 18, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 18, 2026

No actionable comments were generated in the recent review. 🎉


📝 Walkthrough

Walkthrough

A public class field in an Angular example component is converted to a private field using private field syntax, changing queryClient to #queryClient. The injected QueryClient remains functional with no behavioral modifications.

Changes

Cohort / File(s) Summary
Documentation Example Refactoring
docs/framework/angular/guides/paginated-queries.md
Converted public queryClient field to private #queryClient field in PaginationExampleComponent, improving encapsulation without altering functionality.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Possibly related PRs

Poem

🐰 A query client once stood in the light,
Now cloaked in shadows, hidden from sight,
With # it whispers, "I'm mine alone,"
Encapsulation's way has grown—
The rabbit approves of secrets well-kept! 🔐

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: fixing the QueryClient field declaration in the Angular paginated guide documentation.
Description check ✅ Passed The description explains the issue and fix clearly: changing from public queryClient to private #queryClient to match usage. The release impact is correctly marked as docs-only.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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 and usage tips.

@nx-cloud
Copy link

nx-cloud bot commented Feb 18, 2026

View your CI Pipeline Execution ↗ for commit 159d1dc

Command Status Duration Result
nx affected --targets=test:sherif,test:knip,tes... ✅ Succeeded 41s View ↗
nx run-many --target=build --exclude=examples/*... ✅ Succeeded <1s View ↗

☁️ Nx Cloud last updated this comment at 2026-02-18 03:15:38 UTC

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 18, 2026

More templates

@tanstack/angular-query-experimental

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

@tanstack/eslint-plugin-query

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

@tanstack/preact-query

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

@tanstack/query-async-storage-persister

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

@tanstack/query-broadcast-client-experimental

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

@tanstack/query-core

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

@tanstack/query-devtools

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

@tanstack/query-persist-client-core

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

@tanstack/query-sync-storage-persister

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

@tanstack/react-query

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

@tanstack/react-query-devtools

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

@tanstack/react-query-next-experimental

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

@tanstack/react-query-persist-client

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

@tanstack/solid-query

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

@tanstack/solid-query-devtools

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

@tanstack/solid-query-persist-client

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

@tanstack/svelte-query

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

@tanstack/svelte-query-devtools

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

@tanstack/svelte-query-persist-client

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

@tanstack/vue-query

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

@tanstack/vue-query-devtools

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

commit: 159d1dc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments