MCPcopy Create free account
hub / github.com/Effect-TS/effect / makeUnsafe

Function makeUnsafe

packages/effect/src/Resource.ts:76–84  ·  view source on GitHub ↗
(
  scopedRef: ScopedRef.ScopedRef<Exit.Exit<A, E>>,
  acquire: Effect.Effect<A, E>
)

Source from the content-addressed store, hash-verified

74}
75
76const makeUnsafe = <A, E>(
77 scopedRef: ScopedRef.ScopedRef<Exit.Exit<A, E>>,
78 acquire: Effect.Effect<A, E>
79): Resource<A, E> => {
80 const self = Object.create(Proto)
81 self.scopedRef = scopedRef
82 self.acquire = acquire
83 return self
84}
85
86/**
87 * Creates a `Resource` that must be refreshed manually.

Callers 1

manualFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected