“react”:“^ 15.2.1”,
“react-native”:“^ 0.30.0”,
我开始收到很多关于样式表的警告。我实际上没有使用React.PropTypes验证的样式表,那么为什么抛出这些警告?
const styles = StyleSheet.create({ welcome: { fontSize: 20,textAlign: "center",margin: 10,},
ExceptionsManager.js:76 Warning: You are manually calling a
React.PropTypes validation function for thefontSize
prop on
StyleSheet welcome
. This is deprecated and will not work in the next
major version. You may be seeing this warning due to a third-party
PropTypes library. See 07000
for details.reactConsoleError @ExceptionsManager.js:76 Warning: You are manually calling a
React.PropTypes validation function for thetextAlign
prop on
StyleSheet welcome
. This is deprecated and will not work in the next
major version. You may be seeing this warning due to a third-party
PropTypes library. See 07000ExceptionsManager.js:76 Warning: You are manually calling a
React.PropTypes validation function for themargin
prop on
StyleSheet welcome
. This is deprecated and will not work in the next
major version. You may be seeing this warning due to a third-party
PropTypes library. See 07000
for details.
原文地址:https://www.jb51.cc/react/302011.html
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。