I don\'t know if I\'m doing this correctly... If I want to get value from an input I use this.refs.whatever.value.trim() but if that input is a stateless function component
Nowadays, you would want to avoid to use the ref attribute to get values from input fields. Instead you should use React's local state. The ref attribute is reserved for only a few use cases: