def text.value

ezsys@0.1.0.0 · src/text.bend:42

import ezsys@0.1.0.0/src/text.bend as Text
import Base

42# the value a key names: the first pair with that key
43def text.value(pairs: text.Pairs(), +key: String) -> Maybe<&2, String>:
44  match pairs:
45    case Nil{}:
46      None{}
47    case Con{(name, value), rest}:
48      text.value.pick(String.eq(name, key), value,
49        _u => text.value(rest, key))

Uses (7)

Used by (1)