Skip to content
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

showTabBarRedDot, setTabBarBadge设置后无反应,需要点击下tab才会生效 #8175

Closed
xiehui999 opened this issue Dec 2, 2020 · 4 comments · Fixed by #10658
Closed
Labels
F-react Framework - React T-h5 Target - 编译到 H5 V-3 Version - 3.x
Projects
Milestone

Comments

@xiehui999
Copy link

相关平台

H5

浏览器版本: 浏览器手机版本都有问题
使用框架: React

复现步骤

随便创建一个demo, 带有tab,手机浏览器谷歌,safari 都有问题,我看了源码应该是设置之后没有重绘,所以需要点击后才生效。还有H5调用 setTabBarItem, setTabBarStyle 时直接失败了,源码里packages/taro-h5/src/api/tabBar/index.js,中 tabConf没有值,这个需要什么处理? 文档没有相关说明

期望结果

设置正常显示,而不是点击tab

实际结果

设置后不生效,点击tab后生效

环境信息

� Taro v3.0.14


  Taro CLI 3.0.14 environment info:
    System:
      OS: Windows 10
    Binaries:
      Node: 12.18.3 - C:\Program Files\nodejs\node.EXE
      Yarn: 1.22.4 - C:\Users\root\AppData\Roaming\npm\yarn.CMD
      npm: 6.14.6 - C:\Program Files\nodejs\npm.CMD

@taro-bot2 taro-bot2 bot added F-react Framework - React T-h5 Target - 编译到 H5 V-3 Version - 3.x labels Dec 2, 2020
@jarmywang
Copy link

遇到了同样的问题

@daiyuanhao
Copy link

这个解决了吗,我使用h5上使用setTabBarItem方法直接报错了,{errMsg: "setTabBarItem:fail tabbar item not found"}

@Rambos
Copy link

Rambos commented Apr 28, 2021

遇到了这个问题,H5上设置后必须切换下页面才会生效

@shiyachuang
Copy link

这个问题何时能修复?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-react Framework - React T-h5 Target - 编译到 H5 V-3 Version - 3.x
Projects
Archived in project
H5
  
Done
Development

Successfully merging a pull request may close this issue.

6 participants