Skip to content

start useRxQuery loading state as true#8292

Closed
apaleslimghost wants to merge 1 commit intopubkey:masterfrom
apaleslimghost:patch-1
Closed

start useRxQuery loading state as true#8292
apaleslimghost wants to merge 1 commit intopubkey:masterfrom
apaleslimghost:patch-1

Conversation

@apaleslimghost
Copy link
Copy Markdown
Contributor

i feel like i must be missing something here! it seems like nothing actually sets loading to true; in my app this meant it rendered the regular component instead of the placeholder, which threw because the result hadn't been populated yet, so it never actually got to run the query.

there aren't any existing tests for the React hooks, so i haven't added one.

i feel like i must be missing something here! it seems like nothing actually sets `loading` to `true`; in my app this meant it rendered the regular component instead of the placeholder, which threw because the result hadn't been populated yet, so it never actually got to run the query.

there aren't any existing tests for the React hooks, so i haven't added one.
@pubkey
Copy link
Copy Markdown
Owner

pubkey commented Apr 7, 2026

Thanks for reporting, let me add a test suite first: #8294

@pubkey pubkey closed this Apr 7, 2026
Copilot AI added a commit that referenced this pull request Apr 7, 2026
pubkey added a commit that referenced this pull request Apr 7, 2026
…ding state (#8294)

* Add react-hooks test file, test entry point, and test:react npm script; fix loading state bug in useRxQuery

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/0dc0384e-4293-4e8e-8833-f0fbda27c794

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Fix lint issues in react-hooks test file

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/0dc0384e-4293-4e8e-8833-f0fbda27c794

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Add test:react step to core job in CI workflow

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/54f4c9b9-cc0b-484a-a624-394193b22460

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Move react-hooks test from test/unit to test/react folder

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/d4faebfb-e148-444b-b08d-d07c124ff550

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Add changelog entry for useRxQuery loading state fix (#8292)

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/f3030f4c-5865-406f-8035-ec65a8cf6aa4

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Add tsconfig.json to tauri example to prevent root test files from breaking its build

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/eb340f4e-dcf6-4fe9-8c0f-c22f93364387

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

* Fix tauri example build: exclude react test files from root tsconfig instead of adding local tsconfig

Agent-Logs-Url: https://github.com/pubkey/rxdb/sessions/d91d73ea-b9cd-41bf-9709-7cc3f7d99e43

Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: pubkey <8926560+pubkey@users.noreply.github.com>
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