Skip to content
Source
Sign inSign up
TanStack/db
Open History to see the last commit

app-effect.js

10 lines269 Bytes

1// The typical app, plus an Effect that reacts to a live query.
2import { createEffect } from '@tanstack/db'
3import { todos } from './app.js'
4​
5export * from './app.js'
6​
7createEffect({
8 query: (q) => q.from({ todo: todos }),
9 onBatch: (batch) => console.log(batch),
10})