Commit 98e44f7
useSubscription: fix rules of React violations (#11863)
* Revert "Merge pull request #9707 from kazekyo/fix_usesubscription_in_strict_mode"
This reverts commit 4571e1a, reversing
changes made to 5be85a0.
* essentially rewrite useSubscription
* use `setResult` update method
* adjust tests
* change observable during render; lazy initialization of subscription
* no more need for stable options, performance optimization
* changeset
* adjust documentation
* review feedback
* Apply suggestions from code review
Co-authored-by: Jerel Miller <jerelmiller@gmail.com>
* clarify comment
* update size-limits
* fix test
---------
Co-authored-by: Jerel Miller <jerelmiller@gmail.com>1 parent ffb21ce commit 98e44f7
File tree
6 files changed
+370
-356
lines changed- .changeset
- src
- react
- components/__tests__/client
- hoc/__tests__/subscriptions
- hooks
- testing/react/__tests__
6 files changed
+370
-356
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
0 commit comments