Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Effect-TS/effect
/ toArray
Function
toArray
packages/effect/src/Option.ts:1764–1764 ·
view source on GitHub ↗
(self: Option<A>)
Source
from the content-addressed store, hash-verified
1762
* @since 2.0.0
1763
*/
1764
export
const
toArray = <A>(self: Option<A>): Array<A> => isNone(self) ? [] : [self.value]
1765
1766
/**
1767
* Splits an `Option` into two `Option`s using a
function
that returns a `Result`.
Callers
nothing calls this directly
Calls
1
isNone
Function · 0.85
Tested by
no test coverage detected