How to get an input value using “refs” in react-bootstrap form?

前端 未结 7 751
小蘑菇
小蘑菇 2021-02-05 04:01

I\'m trying to create a form that appears in modal. So when user input a value, that value is stored in local storage. Here\'s a picture that help\'s you to understand what I me

7条回答
  •  太阳男子
    2021-02-05 04:59

    Hello this solution worked for me!

    this.handleSubmit(e)} style={{ width: '100%' }} > Email address { this.email = ref }} required /> Well never share your email with anyone else.
    handleSubmit(event) { console.log(event.target.elements.formBasicPassword.value) }

提交回复
热议问题