Witchcraft v1.0.0-beta.2 Witchcraft.Comonad.Proto protocol View Source
Protocol for the Elixir.Witchcraft.Comonad
type class
For this type class’s API, please refer to Elixir.Witchcraft.Comonad
Link to this section Summary
Functions
Extract a value out of some context / data structure. This is the opposite
of Witchcraft.Applicative.of/2
Link to this section Types
Link to this section Functions
Extract a value out of some context / data structure. This is the opposite
of Witchcraft.Applicative.of/2
.
Examples
iex> extract({1, 2})
2
extract(%Id{id: 42})
#=> 42