Skip to content

refactor(MaskedTextInput): optimize state management and value updates#319

Open
AndreyPassos wants to merge 2 commits intoakinncar:mainfrom
AndreyPassos:fix/masked-input-sync-mask-typing
Open

refactor(MaskedTextInput): optimize state management and value updates#319
AndreyPassos wants to merge 2 commits intoakinncar:mainfrom
AndreyPassos:fix/masked-input-sync-mask-typing

Conversation

@AndreyPassos
Copy link

  • Replace multiple state updates with a single ref to track latest values
  • Add requestAnimationFrame and setTimeout for efficient value emission
  • Remove unnecessary state for unmaskedValue and initial render check
  • Clean up animation frame and timeout handlers in useEffect cleanup

…havior

- Add tests for textBold, textItalic, and textDecoration props
- Verify onChangeText is called with correct values
- Ensure onChangeText is not called on mount
- Replace multiple state updates with a single ref to track latest values
- Add requestAnimationFrame and setTimeout for efficient value emission
- Remove unnecessary state for unmaskedValue and initial render check
- Clean up animation frame and timeout handlers in useEffect cleanup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant