Material-ui: Updating TextField value shows warning in console.

Created on 21 Apr 2016  ·  3Comments  ·  Source: mui-org/material-ui

Problem Description

When I update the state of value of a TextField, I get this warning from [email protected]

Warning: TextField is changing a uncontrolled input of type text to be controlled. Input elements should not switch from uncontrolled to controlled (or vice versa). Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://fb.me/react-controlled-components.

Versions

"react": "^15.0.0",
"material-ui": "^0.15.0-beta.1",
"redux": "^3.3.1",
"react-redux": "^4.4.1"

Chrome: 49.0.2623.110 (64-bit)

Most helpful comment

Sorry my bad, the initial value that was being sent to TextField was null, which was causing that warning to show up.

All 3 comments

@mb-copart : Hi, Could you explain your use-case a bit more in detail. Its very difficult to debug based on the default warning message.

Please follow the https://github.com/callemall/material-ui/blob/master/CONTRIBUTING.md document for further guidelines.

Sorry my bad, the initial value that was being sent to TextField was null, which was causing that warning to show up.

@tintin1343 this kind of issue can be closed IMO -- it's a user implementation issue not a material-ui issue and unfortunately we don't have the manpower to debug bugs that aren't material-ui related.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pola88 picture pola88  ·  3Comments

joewalker picture joewalker  ·  3Comments

ghost picture ghost  ·  3Comments

revskill10 picture revskill10  ·  3Comments

finaiized picture finaiized  ·  3Comments