0.1.0 #1
@@ -1,5 +1,4 @@
|
||||
import { Effect, Exit, Fiber, ManagedRuntime, Ref, Stream, SubscriptionRef } from "effect"
|
||||
import type { RunForkOptions } from "effect/Runtime"
|
||||
import { Effect, Exit, Fiber, ManagedRuntime, Ref, Runtime, Stream, SubscriptionRef } from "effect"
|
||||
import React from "react"
|
||||
|
||||
|
||||
@@ -49,7 +48,7 @@ export class Reffuse<R, ER> {
|
||||
|
||||
runFork<A, E>(
|
||||
self: Effect.Effect<A, E, R>,
|
||||
options?: RunForkOptions,
|
||||
options?: Runtime.RunForkOptions,
|
||||
): Fiber.RuntimeFiber<A, ER | E> {
|
||||
return this.useRuntime().runFork(self, options)
|
||||
}
|
||||
@@ -58,7 +57,7 @@ export class Reffuse<R, ER> {
|
||||
useFork<A, E>(
|
||||
self: Effect.Effect<A, E, R>,
|
||||
deps?: React.DependencyList,
|
||||
options?: RunForkOptions,
|
||||
options?: Runtime.RunForkOptions,
|
||||
): void {
|
||||
return React.useEffect(() => {
|
||||
const fiber = this.runFork(self.pipe(Effect.scoped), options)
|
||||
|
||||
Reference in New Issue
Block a user