react报错: dispatch is not a function,需要在类前添加@connect(() => ({})) import {connect} from 'dva'
@connect(({ testHome }) => ({
testHome
}))
class Methods extends Component{ }
models文件定义 export default { namespace: 'testHome', }
2024-03-24 16:25:04
react报错: dispatch is not a function,需要在类前添加@connect(() => ({})) import {connect} from 'dva'
@connect(({ testHome }) => ({
testHome
}))
class Methods extends Component{ }
models文件定义 export default { namespace: 'testHome', }