We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
微信小程序
小程序基础库: 3.3.4 使用框架: React
主包分包页面都设置了 PageMeta,主包中的页面跳转进入分包页面,属性不生效。
用开发工具设置当前分包页面为启动页面时,PageMeta 的属性可以生效,普通跳转进入的方式属性是设置不上去的。
代码很简单就可以复现:
// 主包页面,字体正常,PageMeta 属性可以设置 <> <PageMeta rootFontSize='30px' /> <Navigator url='/pages/sub/index'>跳转 sub 分包页面</Navigator> </> // 分包页面,由链接跳转过来,PageMeta 设置的属性丢失 <> <PageMeta rootFontSize='30px' /> <View>SubPage</View> </>
分包页面中的属性能够设置上
分包中的属性,例如 rootFontSize、pageFontSize 等都未生效,标签元素内不存在这些属性
👽 Taro v3.6.23 Taro CLI 3.6.23 environment info: System: OS: Windows 11 10.0.22621 Binaries: Node: 20.8.1 - D:\Node\node.EXE Yarn: 1.22.19 - ~\AppData\Roaming\npm\yarn.CMD npm: 10.1.0 - D:\Node\npm.CMD npmPackages: @tarojs/cli: 3.6.23 => 3.6.23 @tarojs/components: 3.6.23 => 3.6.23 @tarojs/helper: 3.6.23 => 3.6.23 @tarojs/plugin-framework-react: 3.6.23 => 3.6.23 @tarojs/plugin-platform-alipay: 3.6.23 => 3.6.23 @tarojs/plugin-platform-h5: 3.6.23 => 3.6.23 @tarojs/plugin-platform-jd: 3.6.23 => 3.6.23 @tarojs/plugin-platform-qq: 3.6.23 => 3.6.23 @tarojs/plugin-platform-swan: 3.6.23 => 3.6.23 @tarojs/plugin-platform-tt: 3.6.23 => 3.6.23 @tarojs/plugin-platform-weapp: 3.6.23 => 3.6.23 @tarojs/react: 3.6.23 => 3.6.23 @tarojs/runtime: 3.6.23 => 3.6.23 @tarojs/shared: 3.6.23 => 3.6.23 @tarojs/taro: 3.6.23 => 3.6.23 @tarojs/taro-loader: 3.6.23 => 3.6.23 @tarojs/webpack5-runner: 3.6.23 => 3.6.23 babel-preset-taro: 3.6.23 => 3.6.23 eslint-config-taro: 3.6.23 => 3.6.23 react: ^18.0.0 => 18.2.0
The text was updated successfully, but these errors were encountered:
又测试了一下,跟分包没关系,只要是跳转的目标页面设置了PageMeta就不行,属性不生效
Sorry, something went wrong.
fix: fix set pagemeta when there are multiple pages
63c4952
NervJS#15346
fix: fix set pagemeta when there are multiple pages (#15350)
a9246c2
* fix: fix set pagemeta when there are multiple pages #15346 * test: update snapshot --------- Co-authored-by: Li,Weitao <weitaozsh@gmail.com>
Successfully merging a pull request may close this issue.
相关平台
微信小程序
小程序基础库: 3.3.4
使用框架: React
复现步骤
主包分包页面都设置了 PageMeta,主包中的页面跳转进入分包页面,属性不生效。
用开发工具设置当前分包页面为启动页面时,PageMeta 的属性可以生效,普通跳转进入的方式属性是设置不上去的。
代码很简单就可以复现:
期望结果
分包页面中的属性能够设置上
实际结果
分包中的属性,例如 rootFontSize、pageFontSize 等都未生效,标签元素内不存在这些属性
环境信息
The text was updated successfully, but these errors were encountered: