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

ShareElement 组件没有入场动画 #17044

Open
mushan0x0 opened this issue Dec 17, 2024 · 1 comment
Open

ShareElement 组件没有入场动画 #17044

mushan0x0 opened this issue Dec 17, 2024 · 1 comment

Comments

@mushan0x0
Copy link
Contributor

mushan0x0 commented Dec 17, 2024

复现仓库

https://github.com/mushan0x0/taro-demo-1

相关平台

微信小程序

小程序基础库: 3.7.1
使用框架: React

复现步骤

点击 a 页面方块,跳转 b 页面,模拟器偶尔会没有入场动画,真机很容易出现

ScreenRecording_12-17-2024.23-00-14_1.MP4

官方例子不会有这问题

ScreenRecording_12-17-2024.23-02-24_1.MP4

期望结果

b 页面 ShareElement 有入场动画

实际结果

有概率 b 页面 ShareElement 没有入场动画

其他信息

官方文档这里说了有可能是 setData() 动态渲染页面的时候丢了首帧导致的,可能要使用 Component 构造页面用 attached 生命周期来 setData() 不知道 Taro 是不是这样,我试了开启预渲染也没有解决

image

环境信息

👽 Taro v4.0.8


  Taro CLI 4.0.8 environment info:
    System:
      OS: macOS 15.1.1
      Shell: 5.9 - /bin/zsh
    Binaries:
      Node: 18.19.0 - ~/.nvm/versions/node/v18.19.0/bin/node
      Yarn: 1.22.1 - ~/.nvm/versions/node/v18.19.0/bin/yarn
      npm: 10.2.3 - ~/.nvm/versions/node/v18.19.0/bin/npm
    npmPackages:
      @tarojs/cli: 4.0.8 => 4.0.8 
      @tarojs/components: 4.0.8 => 4.0.8 
      @tarojs/helper: 4.0.8 => 4.0.8 
      @tarojs/plugin-framework-react: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-alipay: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-h5: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-harmony-hybrid: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-jd: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-qq: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-swan: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-tt: 4.0.8 => 4.0.8 
      @tarojs/plugin-platform-weapp: 4.0.8 => 4.0.8 
      @tarojs/react: 4.0.8 => 4.0.8 
      @tarojs/runtime: 4.0.8 => 4.0.8 
      @tarojs/shared: 4.0.8 => 4.0.8 
      @tarojs/taro: 4.0.8 => 4.0.8 
      @tarojs/taro-loader: 4.0.8 => 4.0.8 
      @tarojs/webpack5-runner: 4.0.8 => 4.0.8 
      babel-preset-taro: 4.0.8 => 4.0.8 
      eslint-config-taro: 4.0.8 => 4.0.8 
      react: ^18.0.0 => 18.3.1 


@mushan0x0
Copy link
Contributor Author

mushan0x0 commented Dec 18, 2024

@tutuxxx @ZakaryCode 这是 skyline 模式下的问题,可以看看吗

This was referenced Dec 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant