0.1.13 #18

Merged
Thilawyn merged 359 commits from next into master 2025-06-18 00:12:19 +02:00
Showing only changes of commit f25fefb0f3 - Show all commits

View File

@@ -1,24 +1,7 @@
import type * as AsyncData from "@typed/async-data" import { Effect } from "effect"
import { type Cause, Effect, type Fiber, type Option, type Stream, type SubscriptionRef } from "effect"
import * as QueryRunner from "./QueryRunner.js" import * as QueryRunner from "./QueryRunner.js"
import * as QueryProgress from "./QueryProgress.js"
export const Tag = <const Id extends string>(id: Id) => < export const Tag = <const Id extends string>(id: Id) => <
Self, K extends readonly unknown[], A, E = never Self, K extends readonly unknown[], A, E = never
>() => Effect.Tag(id)<Self, QueryRunner.QueryRunner<K, A, E>>() >() => Effect.Tag(id)<Self, QueryRunner.QueryRunner<K, A, E>>()
export interface ServiceProps<K extends readonly unknown[], A, E, R> {
readonly key: Stream.Stream<K>
readonly query: (key: K) => Effect.Effect<A, E, R | QueryProgress.QueryProgress>
readonly options?: QueryRunner.RunOptions
}
export const Service = <Self>() => <
const Id extends string,
K extends readonly unknown[], A, E, R,
>(
id: Id,
props: ServiceProps<K, A, E, R>,
) =>