Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

SSR and hydration support for @tanstack/angular-db

Aberta
#1,965 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
45/100
Tipo de issue
Funcionalidade
Clareza
Razoavelmente clara
Status de atividade
Ativa
Stack de tecnologia
angular, typescript
Domínio
backend, frontend, testing

Direção de pesquisa

Start with the core DbClient dehydration/hydration payload and observer contract from #1564, then trace injectLiveQuery and Angular DI through an SSR request and browser hydration path. Add a real Angular SSR/hydration integration or E2E test covering independent requests and a post-hydration live update; done means matching initial rows and order without duplicates or hydration errors, plus documented setup and unsupported query forms.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Follow-up to #1623 (Phase 6). #1564 added core DbClient, collection descriptors, and dehydration/hydration, while Angular still needs its own client/SSR integration.

Goal

Make injectLiveQuery work during Angular server rendering with a request-scoped DbClient, and hydrate the result into the browser client before components first read it. Keep Angular DI and signals as the public integration model.

Acceptance criteria

  • Provide an Angular DI provider/token (or equivalent idiomatic API) for DbClient. A server request gets a fresh client; the browser keeps a stable client. Existing direct-collection queries continue to work.
  • injectLiveQuery can resolve collection descriptors through that client and render preloaded collection or live-query results on the server. dbClient.dehydrate() supplies the state to transfer.
  • Transfer and hydrate the state before the first browser query read (using Angular TransferState or an equivalent mechanism). Initial rows and order match server HTML; normal sync then takes over without duplicates or hydration errors.
  • Add an integration or E2E test through a real Angular SSR/hydration path. Cover independent requests and a live update after hydration.
  • Document the DI/server setup and any unsupported query forms.

Reuse the core SSR payload and observer contract; avoid a separate Angular-only state format.

Linguagem predominante
TypeScript
Estrelas
4k
Forks
277
Merge médio
1d 4h
PRs com merge (30d)
212

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de TanStack/db

Todas as issues de TanStack/db

Issues semelhantes

Mais issues de TypeScript

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.