Using window.performance.memory.usedJSHeapSize
, I am attempting to monitor the memory consumption of my web application in real time.
There is a large discrepancy between the value returned by the performance API and the value the Chrome Timeline shows that I do not understand.
At application start both are about 20mb
.
After some navigating around meant to detect a memory leak, Chrome Timeline shows much more usage (say, 150mb), and window.performance.memory.usedJSHeapSize
changes very slightly (say, 20.69mb).
Is this value measuring something different than I think it's measuring? Why the discrepancy?