升级处理新设备后,我的应用程序在启动画面停止时遇到问题。我正在运行以下内容。
"react": "^16.2.0",
"react-native": "^0.51.0",
打包器中没有错误,但在xCode中我看到以下
Unhandled JS Exception: Module AppRegistry is not a registered
callable module (calling runApplication)
和
[tid:com.facebook.react.ExceptionsManagerQueue] Unhandled JS
Exception: undefined is not an object (evaluating '_react2.PropTypes.oneOf')
任何有助于追踪这些错误的人都会受到赞赏。
答案 0 :(得分:3)
PropTypes已从React v16及更高版本的React包移开。
您的代码中某处有React.PropTypes
或者像import { PropTypes } from 'react'
这样的导入语句
您必须通过导入这样的PropType来更改此项:
import PropTypes from 'prop-types'; // ES6
并像这样使用它。
MyComponent.propTypes = {
props: PropTypes.string
}
您还必须确保在package.json
dependencies
内prop-types
内有npm install --save prop-types
依赖关系,例如运行:
class New_Toplevel_1:
def __init__(self, top=None):
self.Scrolledlistbox4.configure(background="white")
self.Scrolledlistbox4.configure(font="TkFixedFont")
self.Scrolledlistbox4.configure(highlightcolor="#d9d9d9")
self.Scrolledlistbox4.configure(selectbackground="#c4c4c4")
self.Scrolledlistbox4.configure(width=10)