Fix multiline TextInput crash when inserting/removing lots of text (#29307)
Fix multiline TextInput crash when inserting/removing lots of text (#29307)

Summary:
Multiline `TextInput` can crash when really long texts are inserted and removed quickly. This is caused by the fact that [`-[NSAttributedString string]`](https://developer.apple.com/documentation/foundation/nsattributedstring/1412616-string?language=objc) doesn't really return a copy, and may mutate the string while it is being used by `convertIdToFollyDynamic`. See https://github.com/microsoft/react-native-macos/pull/489#discussion_r451789471 for more details on the issue.

This issue was originally reported in https://github.com/microsoft/react-native-macos/issues/486 and was fixed in https://github.com/microsoft/react-native-macos/pull/489.

## Changelog

[iOS] [Fixed] - Fix multiline TextInput crash when inserting/removing lots of text

Pull Request resolved: https://github.com/facebook/react-native/pull/29307

Test Plan:
1. Open RNTester > TextInput
2. Search for a multiline example
3. Copy some large text and paste it into the text input view
4. Remove some (or all) text
5. Repeat steps 3-4

Reviewed By: shergin

Differential Revision: D22488854

Pulled By: JoshuaGross

fbshipit-source-id: 6fab7818d68538450d93460361ff5934caf86c10

janicduplessis/react-native,myntra/react-native,hoangpham95/react-native,javache/react-native,javache/react-native,janicduplessis/react-native,pandiaraj44/react-native,hoangpham95/react-native,hoangpham95/react-native,facebook/react-native,pandiaraj44/react-native,facebook/react-native,myntra/react-native,pandiaraj44/react-native,facebook/react-native,myntra/react-native,arthuralee/react-native,janicduplessis/react-native,pandiaraj44/react-native,pandiaraj44/react-native,javache/react-native,janicduplessis/react-native,pandiaraj44/react-native,arthuralee/react-native,javache/react-native,arthuralee/react-native,facebook/react-native,janicduplessis/react-native,myntra/react-native,pandiaraj44/react-native,hoangpham95/react-native,janicduplessis/react-native,javache/react-native,myntra/react-native,facebook/react-native,javache/react-native,javache/react-native,janicduplessis/react-native,javache/react-native,janicduplessis/react-native,facebook/react-native,facebook/react-native,myntra/react-native,pandiaraj44/react-native,myntra/react-native,facebook/react-native,myntra/react-native,arthuralee/react-native,hoangpham95/react-native,arthuralee/react-native,facebook/react-native,hoangpham95/react-native,myntra/react-native,hoangpham95/react-native,hoangpham95/react-native,javache/react-native