-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Taro3.6.30 react-native上 使用react-redux的页面无法触发componentDidShow #16858
Comments
Slngle
changed the title
使用react-redux的页面无法触发componentDidShow
Taro3.6.30 react-native上 使用react-redux的页面无法触发componentDidShow
Nov 15, 2024
已解决 realName: userInfo.realName, }),null,null,{ forwardRef:true }) |
需要判断下环境 不然小程序的didShow出不来了 realName: userInfo.realName, }),null,null,{ forwardRef:process.env.TARO_ENV }) |
This was referenced Nov 16, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
相关平台
React Native
使用框架: React
复现步骤
import { Component } from 'react'
import { View } from '@tarojs/components'
import { connect } from 'react-redux'
@connect(({ userInfo }) => ({
realName: userInfo.realName,
}))
export default class MyPage extends Component {
componentDidMount() {
}
componentDidShow() {
}
render() {
}
}
期望结果
控制台打出 componentDidMount componentDidShow
实际结果
只打出 componentDidMount
环境信息
补充信息
猜测是高阶产生的问题被react-redux重写。但是里面taro本身react-native实现componentDIdShow可能也用的是高阶
The text was updated successfully, but these errors were encountered: