Skip to content

Instantly share code, notes, and snippets.

@jasdev

jasdev/materialize_value.swift Secret

Last active Mar 30, 2020
Embed
What would you like to do?
`Publisher.materialize` with value event handling.
extension Publisher {
func materialize() -> AnyPublisher<Event<Output, Failure>, Never> {
map(Event.value) /// (1) Leaning on Swift’s generation of static, injection
/// functions for each case. i.e. `Event.value: (Output) -> Event`.
/**/
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment