gothinkster / react-redux-realworld-example-app

Exemplary real world application built with React + Redux
https://react-redux.realworld.io
MIT License
5.57k stars 2.51k forks source link

Forms are changing uncontrolled input of type text to controlled. #37

Open hhsadiq opened 7 years ago

hhsadiq commented 7 years ago

In application, the forms are changing uncontrolled input of type text to controlled. Here is error screenshot.

image

It can be fixed if we add default values in render(). For example in Register.js

Change this

    const email = this.props.email;
    const password = this.props.password;
    const username = this.props.username;

to

    const email = this.props.email || '';
    const password = this.props.password || '';
    const username = this.props.username || '';