TextInput: onContentSizeChange
gut4 opened this issue · 6 comments
gut4 commented
Looks like it's not implemented.
WillSquire commented
Is there a workaround for this? Can't access via onChange={(e) => console.log(e.nativeEvent.contentSize)}
either.
necolas commented
You could implement it in a PR
WillSquire commented
PR?
necolas commented
Pull request. A patch
WillSquire commented
Had a look at doing this. One way is to use canvas
although this isn't very 'cross-platform-ie'. In the interim do you recommend any techniques? Thanks
rxb commented
I might be able to put together a PR for this, but in the meantime for anyone else looking for a way to handle this:
onChange={(event)=>{
const height = event.nativeEvent.srcElement.scrollHeight;
const width = event.nativeEvent.srcElement.scrollWidth;
console.log(`width: ${width} / height: ${height}`);
}}