Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
const load = equals('load')
const unload = complement(load)
const loading = set(lensProp('loading'))
const loadReducer = guard([
[load, loading(true)],
[unload, loading(false)] // runs for all actions except `'load'`
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment