Pick the union option that structurally matches the supplied value.
Heuristic only — picks by JavaScript typeof / array / object class. Returns
undefined when the value's shape doesn't correspond to any option (for
example a null value against a non-nullable union). Callers should
fall back to the first option or render an empty state in that case.
Pick the union option that structurally matches the supplied value.
Heuristic only — picks by JavaScript typeof / array / object class. Returns
undefinedwhen the value's shape doesn't correspond to any option (for example anullvalue against a non-nullable union). Callers should fall back to the first option or render an empty state in that case.