HACKER
TALK
Home
Channels
beta
Bookmarks
Messages
Notifications
Sign In
Comment
Gpjcp
js储存dom元素是引用储存吗?
我想到了一个响应式的实现方式就是把数据与dom存在一个类里,通过getter setter劫持修改数据从而触发直接修改对应的dom,但有个问题是在想如果数据过多会占用很多的内存吗,首先这个性能肯定会比
HD Superman
HD Superman
·2 years ago
Across the Great Wall, we can reach every corner in the world.

可以写一个试试,devtool对比内存使用,一般及时把引用释放出去没有内存问题

Replies
HD Superman
HD Superman
Joined 4 years ago
Across the Great Wall, we can reach every corner in the world.
github.com/hdsuperman
Message
Terms of ServicePrivacy PolicyCookie PolicyMarkdown SyntaxUser PointsUser Feedback© 2025 Shware Inc.