stable
Clone or download
Read-only
Part of story #31177 check my identity when doing a risky action Sometimes we need to apply a function when Option is nothing. So this commit introduces function match(). It takes 2 functions as arguments and apply one of the functions according to Option type. Change-Id: I5cf5335be5f93ae31f250034d454de24ca4d7507
Modified Files
Name | ||||
---|---|---|---|---|
M | lib/frontend/option/README.md | +18 | −0 | Go to diff View file |
M | lib/frontend/option/src/Option.test-d.ts | +30 | −0 | Go to diff View file |
M | lib/frontend/option/src/Option.test.ts | +37 | −0 | Go to diff View file |
M | lib/frontend/option/src/Option.ts | +6 | −0 | Go to diff View file |