Function typefusionRefEffect
- typefusionRefEffect<T>(module): Effect<"schema" extends keyof T
? {
[K in string | number | symbol]: T["schema"][K] extends {
getType: (() => R);
}
? R
: never
}[]
: T extends {
runEffect: ((...args: any[]) => any);
}
? Success<ReturnType<T<T>["runEffect"]>> extends {
data: D;
}
? D
: never
: T extends {
run: ((...args: any[]) => any);
}
? Awaited<ReturnType<T<T>["run"]>>["data"]
: never, ConfigError | DatabaseSelectError, never> Returns Effect<"schema" extends keyof T
? {
[K in string | number | symbol]: T["schema"][K] extends {
getType: (() => R);
}
? R
: never
}[]
: T extends {
runEffect: ((...args: any[]) => any);
}
? Success<ReturnType<T<T>["runEffect"]>> extends {
data: D;
}
? D
: never
: T extends {
run: ((...args: any[]) => any);
}
? Awaited<ReturnType<T<T>["run"]>>["data"]
: never, ConfigError | DatabaseSelectError, never>
Analogous to typefusionRef but for use in Effect.