Giter VIP home page Giter VIP logo

Comments (6)

Zervanto avatar Zervanto commented on June 24, 2024 1

关闭console.warn后,问题解决了, 这个console确实会占用内存,且v8垃圾回收机制下并不会释放掉,在一些需要实时交互大量数据的场景下,积累大量的console信息,长时间内存会爆栈。尽量还是避免出现console信息吧,希望后面有相似问题的小伙伴能有个参考。

from vue-gantt-chart.

w1301625107 avatar w1301625107 commented on June 24, 2024

不影响展示的话可以不用理

from vue-gantt-chart.

jueding920 avatar jueding920 commented on June 24, 2024

嗯嗯,就是有强迫症

from vue-gantt-chart.

Zervanto avatar Zervanto commented on June 24, 2024

大佬你好,这个警告可以关掉吗,因为数据量很大时会有很多这个warn信息,页面长时间轮询并留存,会一直占用内存,最终导致浏览器内存栈溢出,页面崩溃。
或者外部需要做些什么配置可以帮助这个warn不出现。

from vue-gantt-chart.

w1301625107 avatar w1301625107 commented on June 24, 2024

console 会导致页面奔溃吗?如果你不想出现这个warn消息,简单点的方法就是直接重写console.warn 为 noop 函数即可。复杂点的可以去修改代码编译一份去除所有console的包

from vue-gantt-chart.

Zervanto avatar Zervanto commented on June 24, 2024

好的,谢谢指点,应该是我停留时间太久,用了定时器轮询20秒一次,积累产生的问题,我尝试释放定时器还有数组内存,没有很好的效果,后来注意到,放置一天后,这个控制台warn信息有好几万了,清理控制台后,监控内存有明显的下降,我先把这个warn重写,再观察下

from vue-gantt-chart.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.