effect-ts/effect
tldr.page
Match When Filter

"effect": minor

Add Match.whenFilter, a case that runs a Filter once and passes its extracted value to the handler, falling through with the original input when the filter fails.