renato-bohler / redux-form-input-masks

Input masking with redux-form made easy
https://bohler.dev/redux-form-input-masks/
MIT License
138 stars 10 forks source link

select() Not working #61

Closed juniordesenv-zz closed 5 years ago

juniordesenv-zz commented 5 years ago

i'm trying to focus on an input with predifined value with .select(), but the cursor focuses on the input without the selection

juniordesenv-zz commented 5 years ago

I found a way around this, but I think it would be interesting to include a fix for that. I put it to shoot the focus and with a timeout shoot the select..

document.getElementById('#field').focus() setTimeout(() => { document.getElementById('#field').select() }, 10)

renato-bohler commented 5 years ago

Hmm, I don't think this is under this library responsibility. This is more likely a problem with the field component that you are using.