MCPcopy Index your code
hub / github.com/nodejs/node / mark

Function mark

test/fixtures/snapshot/typescript.js:3749–3757  ·  view source on GitHub ↗

* Marks a performance event. * * @param markName The name of the mark.

(markName)

Source from the content-addressed store, hash-verified

3747 * @param markName The name of the mark.
3748 */
3749 function mark(markName) {
3750 var _a;
3751 if (enabled) {
3752 var count = (_a = counts.get(markName)) !== null && _a !== void 0 ? _a : 0;
3753 counts.set(markName, count + 1);
3754 marks.set(markName, ts.timestamp());
3755 performanceImpl === null || performanceImpl === void 0 ? void 0 : performanceImpl.mark(markName);
3756 }
3757 }
3758 performance.mark = mark;
3759 /**
3760 * Adds a performance measurement with the specified name.

Callers 2

enterFunction · 0.70
exitFunction · 0.70

Calls 3

getMethod · 0.65
setMethod · 0.45
markMethod · 0.45

Tested by

no test coverage detected