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

RN ScrollView有bug,只要页面leave,onScroll会被原地trigger一下 #12152

Open
zhiqingchen opened this issue Jul 28, 2022 · 0 comments
Labels
F-react Framework - React T-rn Target - 编译到 React Native V-3 Version - 3.x

Comments

@zhiqingchen
Copy link
Member

zhiqingchen commented Jul 28, 2022

相关平台

React Native

from @yiheyang

使用框架: React

复现步骤

目前RN的ScrollView有bug,只要页面leave,onScroll会被原地trigger一下,所以要过滤一下deltaXY都为0的事件

相关问题:software-mansion/react-native-screens#1183

期望结果

不触发

实际结果

触发

环境信息

👽 Taro v3.4.13

Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating

  Taro CLI 3.4.13 environment info:
    System:
      OS: macOS 12.0.1
      Shell: 5.8 - /bin/zsh
    Binaries:
      Node: 16.10.0 - /usr/local/bin/node
      Yarn: 1.22.11 - ~/.nvm/versions/node/v16.10.0/bin/yarn
      npm: 7.24.0 - ~/.nvm/versions/node/v16.10.0/bin/npm
    npmPackages:
      @tarojs/cli: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/components: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/helper: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-framework-react: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-html: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-alipay: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-jd: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-qq: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-swan: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-tt: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/plugin-platform-weapp: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/react: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/rn-runner: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/router: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/runtime: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/shared: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/taro: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/taro-h5: 3.5.0-alpha.16 => 3.5.0-alpha.16
      @tarojs/taro-rn: 3.5.0-alpha.16 => 3.5.0-alpha.16
      babel-preset-taro: 3.5.0-alpha.16 => 3.5.0-alpha.16
      eslint-config-taro: 3.5.0-alpha.16 => 3.5.0-alpha.16
      expo: ~46.0.1 => 46.0.1
      react: ^17.0.2 => 17.0.2
      react-native: ^0.68.2 => 0.68.2

补充信息

image

过滤一下deltaXY都为0的事件

@taro-bot2 taro-bot2 bot added F-react Framework - React T-rn Target - 编译到 React Native V-3 Version - 3.x labels Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-react Framework - React T-rn Target - 编译到 React Native V-3 Version - 3.x
Projects
None yet
Development

No branches or pull requests

1 participant