TypeError: Super expression must either be null or a function, not undefined

TypeError: Super expression must either be null or a function, not undefined
_inherits
http://localhost:3000/static/js/bundle.js:42168:113
(anonymous function)
http://localhost:3000/static/js/bundle.js:42213:2
./src/index.js
F:/git/nodejs-study/imocc/create-react-app/my-app/src/index.js:24


错误原因:component的c应该是大写的
class Test extends React.component{
constructor(props){
super(props);
}


render(){
console.log(this.props)
return

测试组件


}
}

你可能感兴趣的:(react)