evanrs / redux-namespace

Namespace component state into a Redux store
MIT License
18 stars 3 forks source link

Separate default value from value #25

Open evanrs opened 8 years ago

evanrs commented 8 years ago

When assigning a value identical to the default value no update occurs because they are equal. This leads to a confusing bug where a value should be touched but is not.

ns.defaults('value', 1)
ns.assign('value', 1)
ns.touched('value')
// false