A react example to update text from input