mirror of
https://github.com/zhigang1992/redux.git
synced 2026-04-29 12:55:33 +08:00
docs/recipes/UsingObjectSpreadOperator: tenants != tenets :)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Using Object Spread Operator
|
||||
|
||||
Since one of the core tenants of Redux is to never mutate state, you’ll often find yourself using [`Object.assign()`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) to create
|
||||
Since one of the core tenets of Redux is to never mutate state, you’ll often find yourself using [`Object.assign()`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) to create
|
||||
copies of objects with new or updated values. For example, in the `todoApp` below `Object.assign()` is used to return a new
|
||||
`state` object with an updated `visibilityFilter` property:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user