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

state直接存贮dom节点,redux页面会很卡顿 #2483

Open
fupeijie opened this issue Feb 6, 2022 · 1 comment
Open

state直接存贮dom节点,redux页面会很卡顿 #2483

fupeijie opened this issue Feb 6, 2022 · 1 comment

Comments

@fupeijie
Copy link

fupeijie commented Feb 6, 2022

What happens?

redux直接存贮e.target,页面会非常卡顿

How To Reproduce

Steps to reproduce the behavior:
1.截屏2022-02-06 10 50 33
2.截屏2022-02-06 10 51 57
3.截屏2022-02-06 10 52 46
4.截屏2022-02-06 10 53 23

Expected behavior
1.存储dom节点不卡顿或者其他替代方案获取dom节点信息

Context

  • Dva Version:2.4.1
  • Node Version:16.12.1
@geekact
Copy link

geekact commented Apr 15, 2022

redux存的都是plain object,dom节点不适合使用状态管理。我觉得你应该保存的是id或者其它唯一标识

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

2 participants