Commit baad191
Brian Vaughn
useMutableSource hook
useMutableSource() enables React components to safely read from a mutable external source in Concurrent Mode. This API will detect mutations that occur during a render to avoid tearing. It will also automatically schedule updates when the source is mutated1 parent d1bfdfb commit baad191
File tree
11 files changed
+736
-2
lines changed- packages
- react-debug-tools/src
- react-dom/src/server
- react-reconciler/src
- __tests__
- react-test-renderer/src
- react/src
- scripts/error-codes
11 files changed
+736
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
16 | 20 | | |
17 | 21 | | |
18 | 22 | | |
| |||
67 | 71 | | |
68 | 72 | | |
69 | 73 | | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
70 | 82 | | |
71 | 83 | | |
72 | 84 | | |
| |||
224 | 236 | | |
225 | 237 | | |
226 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
227 | 250 | | |
228 | 251 | | |
229 | 252 | | |
| |||
276 | 299 | | |
277 | 300 | | |
278 | 301 | | |
| 302 | + | |
279 | 303 | | |
280 | 304 | | |
281 | 305 | | |
| |||
Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
19 | 23 | | |
20 | 24 | | |
21 | 25 | | |
| |||
459 | 463 | | |
460 | 464 | | |
461 | 465 | | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
462 | 475 | | |
463 | 476 | | |
464 | 477 | | |
| |||
500 | 513 | | |
501 | 514 | | |
502 | 515 | | |
| 516 | + | |
| 517 | + | |
503 | 518 | | |
0 commit comments