react 在服务端渲染 使用material-ui Warning

在 react 构建项目的时候 使用了 服务端渲染
当加入了 material-ui 的时候 出现了 Warning

Warning: React attempted to reuse markup in a container but the
checksum was invalid. This generally means that you are using server
rendering and the markup generated on the server was not what the
client was expecting. React injected new markup to compensate which
works but you have lost many of the benefits of server rendering.
Instead, figure out why the markup being generated is different on the
client or server: (client) tyle="did-flip:true;-webkit-tap-highligh
(server) tyle="did-flip:true;tap-highlight-color:

 material-ui 

<TextField
  style={styles.textfield}
  hintText="用户名"
  underlineFocusStyle={{borderColor: Colors.amber900}}
  defaultValue="" /><br/>
<TextField
  hintText="密码"
  floatingLabelText="Password"
  type="password" /><br/>
<RaisedButton
   style={styles.textfield}
   label="登录" secondary={true} /><br/>
阅读 4.6k
1 个回答
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题