MCPcopy Index your code
hub / github.com/react-grid-layout/react-grid-layout / measureTime

Function measureTime

test/spec/fast-compactor-test.js:82–89  ·  view source on GitHub ↗
(fn, iterations = 100)

Source from the content-addressed store, hash-verified

80
81// Measure execution time
82function measureTime(fn, iterations = 100) {
83 const start = performance.now();
84 for (let i = 0; i < iterations; i++) {
85 fn();
86 }
87 const end = performance.now();
88 return (end - start) / iterations;
89}
90
91describe("Fast Vertical Compactor", () => {
92 describe("Correctness", () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…