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
描述Bug 页面中很多组件会在mousemove时进行render,但实际没有任何意义,影响性能
重现步骤 重现行为的步骤:
期望行为 清晰简洁地描述您期望发生的情况。
屏幕截图 如果适用,添加屏幕截图以帮助说明您的问题。
电脑版(请填写以下信息):
智能手机(请填写以下信息):
其他上下文
apitable/packages/datasheet/src/pc/components/gantt_view/hooks/use_scroller.ts
Lines 38 to 47 in 4392bce
useScroller
ganttHorizontalBarRef
{ current: null }
Lines 69 to 82 in 4392bce
scrollTo
Lines 108 to 110 in 4392bce
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
描述Bug
页面中很多组件会在mousemove时进行render,但实际没有任何意义,影响性能
重现步骤
重现行为的步骤:
期望行为
清晰简洁地描述您期望发生的情况。
屏幕截图
如果适用,添加屏幕截图以帮助说明您的问题。
电脑版(请填写以下信息):
智能手机(请填写以下信息):
其他上下文
apitable/packages/datasheet/src/pc/components/gantt_view/hooks/use_scroller.ts
Lines 38 to 47 in 4392bce
useScroller
为ganttHorizontalBarRef
指定了默认值{ current: null }
, 这样在没有传入ganttHorizontalBarRef
时,每一次调用useScroller
都是会是一个新的ganttHorizontalBarRef
apitable/packages/datasheet/src/pc/components/gantt_view/hooks/use_scroller.ts
Lines 69 to 82 in 4392bce
scrollTo
依赖了ganttHorizontalBarRef
,即每次scrollTo
也是一个新的值apitable/packages/datasheet/src/pc/components/gantt_view/hooks/use_scroller.ts
Lines 108 to 110 in 4392bce
返回的
scrollTo
每次也是新的,导致依赖此函数的整棵组件树会产生大量无用的更新The text was updated successfully, but these errors were encountered: