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

🐛@antv/s2-react 2.0.0-next.21版本, React组件内置重渲染render仍为同步模式,频繁更新组件导致渲染重影异常 #2752

Closed
1 of 5 tasks
riverxs opened this issue May 30, 2024 · 6 comments · Fixed by #2762
Assignees
Labels
🤔 need reproduce 需要一个在线复现链接 next 2.0-next 版本的问题 released on @next

Comments

@riverxs
Copy link

riverxs commented May 30, 2024

🏷 Version

Package Version
@antv/s2 2.0.0-next.21
@antv/s2-react 2.0.0-next.21
@antv/s2-vue

Sheet Type

  • PivotSheet
  • TableSheet
  • GridAnalysisSheet
  • StrategySheet
  • EditableSheet

🖋 Description

@antv/s2 与@antv/s2-react升级2.0版本后,s2的render改为异步渲染,而@antv/s2-react封装的代码内render调用方式仍为同步渲染方式,快速更新React组件导致渲染重影异常,是否应改为异步渲染(不确定)
image

⌨️ Code Snapshots

官方@antv/s2-react代码
image

修复建议:

   await s2Ref.current?.render({
      reloadData: renderOptions!.reloadData,
      reBuildDataSet: renderOptions!.reBuildDataSet,
    });

🔗 Reproduce Link

🤔 Steps to Reproduce

😊 Expected Behavior

😅 Current Behavior

💻 System information

Environment Info
System
Browser
@github-actions github-actions bot added the next 2.0-next 版本的问题 label May 30, 2024
@riverxs riverxs changed the title 🐛@antv/s2-react 2.0.0-next.21版本 React组件内置重渲染render仍然为同步模式,快速更新组件导致渲染重影异常 🐛@antv/s2-react 2.0.0-next.21版本, React组件内置重渲染render仍为同步模式,频繁更新组件导致渲染重影异常 May 30, 2024
@lijinke666
Copy link
Member

直接来个 PR ?

@lijinke666
Copy link
Member

快速更新React组件导致渲染重影异常

快速更新具体是指? 最好提供一个 Demo

@lijinke666 lijinke666 added the 🤔 need reproduce 需要一个在线复现链接 label May 31, 2024
@lijinke666 lijinke666 self-assigned this May 31, 2024
Copy link
Contributor

你好 @riverxs,请提供一个可以在线访问的链接, 或者使用 codesandbox 提供示例并详细说明复现步骤 (查看更多模板), 15 天内未回复issue自动关闭。

Hello, @riverxs, please provide an accessible link or usage codesandbox to describe the reproduction steps (more template). The issue will be closed without any replay within 15 days.

@lijinke666
Copy link
Member

🎉 This issue has been resolved in version @antv/s2-v2.0.0-next.24 🎉

The release is available on:

Your semantic-release bot 📦🚀

@lijinke666
Copy link
Member

🎉 This issue has been resolved in version @antv/s2-react-v2.0.0-next.23 🎉

The release is available on:

Your semantic-release bot 📦🚀

@lijinke666
Copy link
Member

🎉 This issue has been resolved in version @antv/s2-vue-v2.0.0-next.15 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤔 need reproduce 需要一个在线复现链接 next 2.0-next 版本的问题 released on @next
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants