tRPC work

This commit is contained in:
Julien Valverdé
2024-07-01 19:19:20 +02:00
parent 84535e9734
commit 546c14e841
2 changed files with 32 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
import { initTRPC } from "@trpc/server"
import { Context, Effect, FiberSet } from "effect"
export const t = initTRPC.create()
export const run = <A, E, R>(
program: Effect.Effect<A, E, R>
) => Effect.gen(function*() {
const runFork = yield* FiberSet.makeRuntime<R>()
})
const testRouter = Effect.gen(function*() {
return t.router({
test: t.procedure.query(async () => {
})
})
})