react-native-cn-richtext-editor
react-native-cn-richtext-editor copied to clipboard
SetSpan() ends beyond length
i am getting this error while removing value from the text input in the rich text editor
.
@babitakapoor112 Which react-native version are you using? I bet this is an instance of those bugs:
- https://github.com/facebook/react-native/issues/25265
- https://github.com/facebook/react-native/issues/17236
- https://github.com/facebook/react-native/issues/18316
RN TextInput component is unfortunately very unreliable and plagued by this bug which has regressed a lot. I noticed however that expo version of react-native is much more stable, and does not have this bug.
same for me RN 0.60.4
This error appears when I use PureComponent or shouldComponentUpdate
Something broken after 0.60 upgrade on Android. Before 0.60, everything was working as expected on Android, but now when i change selection via inputRef.setNativeProps method during onSelectionChange and if my input text is formatted (with dots for example) it gets crash of setSpan ( x .. x ) beyonds length
Did anyone find any solution?
I am having the same issue on expo sdk 36
"react-native-cn-richtext-editor": "^2.0.0-rc3",
"expo": "~36.0.0",
Fixed in https://github.com/facebook/react-native/commit/6ebd3b046e5b71130281f1a7dbe7220eff95d74a; will be shipped in RN 0.62
"react-native": "0.62.1", "react-native-cn-richtext-editor": "^2.0.0-rc2" issue still exists
How i fix this error:
- Go to File CNTextInput.js in library
- Remove line selection = {selection} in render Text input