Server package: validateOnServer + loadEvents adapter
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 32/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Stack tecnológico
- typescript
Línea de trabajo
Start by reading the parent issue #25 and blocked issue #26 to understand the shared Validation Core and what this package depends on. Then trace the existing core's public functions and package conventions; this issue names no files or tests. Done means the new runtime-agnostic package implements the adapter and direct exports, has mock-based unit tests, and documents transactional isolation and the exclusion-constraint recommendation.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Parent
https://github.com/TanStack/time/issues/25
What to build
Build `@tanstack/time-server` — a runtime-agnostic package that exposes the shared isomorphic Validation Core with a `loadEvents` adapter seam for authoritative server-side validation. The library never opens a database connection; the consumer implements `loadEvents` against their own DB inside their own write transaction.
The package's key export:
```ts
validateOnServer(write, { loadEvents }, ctx) → Promise<conflicts[]>
```
The library computes `getRequiredRange(write)`, calls `loadEvents(range, ctx)` to get the relevant events from the consumer's DB, then runs the same pure Validation Core as the client's advisory checks. Same logic, authoritative data.
Documentation must prominently state: read-validate-write is only race-free inside one transaction with a consistent/locked view. The library provides rules; the consumer provides isolation. A DB exclusion constraint is the recommended backstop for raw time-overlap.
Acceptance criteria
- `@tanstack/time-server` is a new package in the monorepo with no DOM or browser dependencies
- `validateOnServer(write, { loadEvents }, ctx)` calls `loadEvents` with the required range, then runs the Validation Core
- `loadEvents(range, ctx) → Promise<Event[]>` is the only DB seam; the package opens no connections
- The package works in Node, Bun, Deno, and edge runtimes (no Node-specific APIs)
- Unit tests use a mock `loadEvents` — no real DB required
- The package exports the same Validation Core pure functions directly for consumers who want to call them without the adapter orchestration
- Documentation clearly states the transactional-isolation requirement and the DB exclusion constraint recommendation
Blocked by
- Lenguaje dominante
- TypeScript
- Estrellas
- 620
- Forks
- 6
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de TanStack/time
-
Dependency DashboardAbierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 5/100
-
Client/server Data StrategyAbiertoenhancement
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
enhancement
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
enhancement
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
-
Undo/redo moduleAbiertoenhancement
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
Todos los issues de TanStack/time
Issues similares
-
needs-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
microsoft/playwright#43875 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
feature
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
calagopus/panel#285 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 Menos de una hora Aptitud para principiantes 88/100
adobe/react-spectrum#10909 ·
Los mantenedores suelen responder en 1 día
-
Keybind conflict with "Tileset"Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
-
Run the dependency drift checkPosiblemente ocupada @spaceninja la tomó hoy. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 72/100
cloudfour/lighthouse-parade#449 ·
Los mantenedores suelen responder en 1 día