jwohlfert23 / react-native-tag-input

A simple React Native component that creates an input for tags, emails, etc.
MIT License
232 stars 104 forks source link

inputWidth refactor #38

Closed Ashoat closed 6 years ago

Ashoat commented 6 years ago

Currently, inputWidth is determined in the following way:

* the TextInput width starts out as 400, but its container View starts out with an undefined width

My proposal:

** This is meant to be long enough to contain the placeholder. I noticed that without this safeguard, on some platforms (Android I think?) when a new tag is added a newline can temporarily appear and then disappear since the wrapperWidth is temporarily determined based on an out-of-date spaceLeft

Note that this PR is stacked on #37, and is diffed against that PR for easier readability.