Commit c1db41f
Fixed - Text with adjustsFontSizeToFit changes the text layout infinitely (facebook#33135)
Summary:
Fixes the infinite loop explained in the issue facebook#33129 by reverting commit 5902152. PR facebook#31538.
`onCollectExtraUpdates` is part of the node update cycle. By marking the node as updated `markUpdated()` in `onCollectExtraUpdates` we are restarting the update infinitely.
Unfortunately, reverting this PR also reintroduces the original issue facebook#30717 which IMO is minor compared to the infinite loop.
## Changelog
<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->
[Android] [Fixed] - Text with adjustsFontSizeToFit changes the text layout infinitely
Pull Request resolved: facebook#33135
Test Plan:
I added a console.log to the Text `onTextLayout` in [packages/rn-tester/js/examples/Text/TextAdjustsDynamicLayoutExample.js ](https://github.com/facebook/react-native/blob/main/packages/rn-tester/js/examples/Text/TextAdjustsDynamicLayoutExample.js) to see if the infinite loop is gone.


```
Reviewed By: ShikaSD
Differential Revision: D34310218
Pulled By: lunaleaps
fbshipit-source-id: 0d40f49d15c562ec25983145897bd95dc182f8971 parent c56754a commit c1db41f
File tree
1 file changed
+0
-5
lines changed- ReactAndroid/src/main/java/com/facebook/react/views/text
1 file changed
+0
-5
lines changedLines changed: 0 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
343 | 343 | | |
344 | 344 | | |
345 | 345 | | |
346 | | - | |
347 | | - | |
348 | | - | |
349 | | - | |
350 | | - | |
351 | 346 | | |
352 | 347 | | |
353 | 348 | | |
| |||
0 commit comments