takeRecords

The takeRecords() method of the PerformanceObserver interface returns the current list of PerformanceEntry objects stored in the performance observer, emptying it out.

MDN Reference