I don't dig what they're doing, but I do kind of like the idea of a deconstructed getter/setter:
[ get, set ] = getterSetter(defaultValue)
as a wrapper around some stateful, immutable value (mutating the result of the get won't be tracked, that is)
[ get, set ] = getterSetter(defaultValue)
as a wrapper around some stateful, immutable value (mutating the result of the get won't be tracked, that is)
I do, however, like the concept for the react style of render -- being able to grab a getter/setter from that is awesome. They can remove the magic by simply doing:
const [getter, setter] = this.useState(...)