Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,7 @@ world
.updateEach(([position, velocity]) => {}, { changeDetection: 'always' })
```

Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a changed has occured.
Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a change has occurred.

```js
// ❌ This change will not be detected since the array is mutated and will pass the comparison
Expand Down
2 changes: 1 addition & 1 deletion docs/advanced/change-detection.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ world
.updateEach(([position, velocity]) => {}, { changeDetection: 'always' })
```

Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a changed has occured.
Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a change has occurred.

```js
// ❌ This change will not be detected since the array is mutated and will pass the comparison
Expand Down
2 changes: 1 addition & 1 deletion packages/publish/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ world
.updateEach(([position, velocity]) => {}, { changeDetection: 'always' })
```

Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a changed has occured.
Changed detection shallowly compares the scalar values just like React. This means objects and arrays will only be detected as changed if a new object or array is committed to the store. While immutable state is a great design pattern, it creates memory pressure and reduces performance so instead you can mutate and manually flag that a change has occurred.

```js
// ❌ This change will not be detected since the array is mutated and will pass the comparison
Expand Down