Skip to content

Commit

Permalink
Merge branch 'main' into support-define-property
Browse files Browse the repository at this point in the history
  • Loading branch information
dai-shi authored Jul 20, 2023
2 parents cf40408 + 581b5e7 commit 577e63e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/api/utils/derive.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,11 @@ const countersOneAndTwoSelectors = derive({
})
```

In this example even if `baseProxy.counter3` or `baseProxy.counter4` are changed, `countersOneAndTwoSelectors` will re-compute all of the keys in it.
In this example if `baseProxy.counter3` or `baseProxy.counter4` are changed, `countersOneAndTwoSelectors` will re-compute all of the keys in it.

## get sub-objects due to update of unrelated proxies on parent proxy

As noted on his page, re-computation occurs when unrelated properties change. It is possible to use `get` on sub-objects. This has the benefit of not re-computing when properties of the parent object are updated. Example:
As noted on this page, re-computation occurs when unrelated properties change. It is possible to use `get` on sub-objects. This has the benefit of not re-computing when properties of the parent object are updated. Example:

```javascript
const baseProxy = proxy({
Expand Down

0 comments on commit 577e63e

Please sign in to comment.