diff --git a/lib/.eslintrc.yaml b/lib/.eslintrc.yaml index b823f15d1c6433..af95b32cd29e15 100644 --- a/lib/.eslintrc.yaml +++ b/lib/.eslintrc.yaml @@ -287,6 +287,7 @@ overrides: - ./internal/mime.js - ./internal/modules/*.js - ./internal/per_context/messageport.js + - ./internal/perf/*.js - ./internal/policy/*.js - ./internal/priority_queue.js - ./internal/process/*.js diff --git a/lib/internal/perf/event_loop_delay.js b/lib/internal/perf/event_loop_delay.js index 18d7967477e0e4..1c1d657a9a0e61 100644 --- a/lib/internal/perf/event_loop_delay.js +++ b/lib/internal/perf/event_loop_delay.js @@ -9,7 +9,7 @@ const { codes: { ERR_ILLEGAL_CONSTRUCTOR, ERR_INVALID_THIS, - } + }, } = require('internal/errors'); const { diff --git a/lib/internal/perf/nodetiming.js b/lib/internal/perf/nodetiming.js index b0ab9df4473d63..11f877e5d81b44 100644 --- a/lib/internal/perf/nodetiming.js +++ b/lib/internal/perf/nodetiming.js @@ -25,7 +25,7 @@ const { NODE_PERFORMANCE_MILESTONE_LOOP_START, NODE_PERFORMANCE_MILESTONE_LOOP_EXIT, NODE_PERFORMANCE_MILESTONE_BOOTSTRAP_COMPLETE, - NODE_PERFORMANCE_MILESTONE_ENVIRONMENT + NODE_PERFORMANCE_MILESTONE_ENVIRONMENT, }, loopIdleTime, } = internalBinding('performance'); @@ -37,28 +37,28 @@ class PerformanceNodeTiming { __proto__: null, enumerable: true, configurable: true, - value: 'node' + value: 'node', }, entryType: { __proto__: null, enumerable: true, configurable: true, - value: 'node' + value: 'node', }, startTime: { __proto__: null, enumerable: true, configurable: true, - value: 0 + value: 0, }, duration: { __proto__: null, enumerable: true, configurable: true, - get: now + get: now, }, nodeStart: { @@ -67,7 +67,7 @@ class PerformanceNodeTiming { configurable: true, get() { return getMilestoneTimestamp(NODE_PERFORMANCE_MILESTONE_NODE_START); - } + }, }, v8Start: { @@ -76,7 +76,7 @@ class PerformanceNodeTiming { configurable: true, get() { return getMilestoneTimestamp(NODE_PERFORMANCE_MILESTONE_V8_START); - } + }, }, environment: { @@ -85,7 +85,7 @@ class PerformanceNodeTiming { configurable: true, get() { return getMilestoneTimestamp(NODE_PERFORMANCE_MILESTONE_ENVIRONMENT); - } + }, }, loopStart: { @@ -94,7 +94,7 @@ class PerformanceNodeTiming { configurable: true, get() { return getMilestoneTimestamp(NODE_PERFORMANCE_MILESTONE_LOOP_START); - } + }, }, loopExit: { @@ -103,7 +103,7 @@ class PerformanceNodeTiming { configurable: true, get() { return getMilestoneTimestamp(NODE_PERFORMANCE_MILESTONE_LOOP_EXIT); - } + }, }, bootstrapComplete: { @@ -113,7 +113,7 @@ class PerformanceNodeTiming { get() { return getMilestoneTimestamp( NODE_PERFORMANCE_MILESTONE_BOOTSTRAP_COMPLETE); - } + }, }, idleTime: { @@ -121,7 +121,7 @@ class PerformanceNodeTiming { enumerable: true, configurable: true, get: loopIdleTime, - } + }, }); } @@ -130,7 +130,7 @@ class PerformanceNodeTiming { const opts = { ...options, - depth: options.depth == null ? null : options.depth - 1 + depth: options.depth == null ? null : options.depth - 1, }; return `PerformanceNodeTiming ${inspect(this.toJSON(), opts)}`; diff --git a/lib/internal/perf/observe.js b/lib/internal/perf/observe.js index 2529079fdc85d5..b97ae08402260a 100644 --- a/lib/internal/perf/observe.js +++ b/lib/internal/perf/observe.js @@ -213,7 +213,7 @@ class PerformanceObserverEntryList { const opts = { ...options, - depth: options.depth == null ? null : options.depth - 1 + depth: options.depth == null ? null : options.depth - 1, }; return `PerformanceObserverEntryList ${inspect(this[kBuffer], opts)}`; @@ -358,7 +358,7 @@ class PerformanceObserver { const opts = { ...options, - depth: options.depth == null ? null : options.depth - 1 + depth: options.depth == null ? null : options.depth - 1, }; return `PerformanceObserver ${inspect({ diff --git a/lib/internal/perf/performance.js b/lib/internal/perf/performance.js index 77c8c7ae1c4904..0cc90bc95b532b 100644 --- a/lib/internal/perf/performance.js +++ b/lib/internal/perf/performance.js @@ -10,8 +10,8 @@ const { const { codes: { ERR_ILLEGAL_CONSTRUCTOR, - ERR_MISSING_ARGS - } + ERR_MISSING_ARGS, + }, } = require('internal/errors'); const { @@ -47,7 +47,7 @@ const { validateInternalField } = require('internal/validators'); const { convertToInt } = require('internal/webidl'); const { - getTimeOriginTimestamp + getTimeOriginTimestamp, } = internalBinding('performance'); const kPerformanceBrand = Symbol('performance'); @@ -62,7 +62,7 @@ class Performance extends EventTarget { const opts = { ...options, - depth: options.depth == null ? null : options.depth - 1 + depth: options.depth == null ? null : options.depth - 1, }; return `Performance ${inspect({ @@ -235,7 +235,7 @@ const performance = createPerformance(); function dispatchBufferFull(type) { const event = new Event(type, { - [kTrustEvent]: true + [kTrustEvent]: true, }); performance.dispatchEvent(event); } diff --git a/lib/internal/perf/performance_entry.js b/lib/internal/perf/performance_entry.js index f487e575b42ea0..036bfc173bd024 100644 --- a/lib/internal/perf/performance_entry.js +++ b/lib/internal/perf/performance_entry.js @@ -9,7 +9,7 @@ const { const { codes: { ERR_ILLEGAL_CONSTRUCTOR, - } + }, } = require('internal/errors'); const { @@ -60,7 +60,7 @@ class PerformanceEntry { const opts = { ...options, - depth: options.depth == null ? null : options.depth - 1 + depth: options.depth == null ? null : options.depth - 1, }; return `${this.constructor.name} ${inspect(this.toJSON(), opts)}`; diff --git a/lib/internal/perf/resource_timing.js b/lib/internal/perf/resource_timing.js index b98295b8426694..13f25d0af79cf7 100644 --- a/lib/internal/perf/resource_timing.js +++ b/lib/internal/perf/resource_timing.js @@ -14,7 +14,7 @@ const { enqueue, bufferResourceTiming } = require('internal/perf/observe'); const { codes: { ERR_ILLEGAL_CONSTRUCTOR, - } + }, } = require('internal/errors'); const { validateInternalField } = require('internal/validators'); const { kEnumerableProperty } = require('internal/util'); diff --git a/lib/internal/perf/timerify.js b/lib/internal/perf/timerify.js index 5dce317be76303..ad959aa42f0c75 100644 --- a/lib/internal/perf/timerify.js +++ b/lib/internal/perf/timerify.js @@ -17,7 +17,7 @@ const { } = require('internal/validators'); const { - isHistogram + isHistogram, } = require('internal/histogram'); const { @@ -57,7 +57,7 @@ function timerify(fn, options = kEmptyObject) { validateObject(options, 'options'); const { - histogram + histogram, } = options; if (histogram !== undefined && @@ -99,8 +99,8 @@ function timerify(fn, options = kEmptyObject) { __proto__: null, configurable: false, enumerable: true, - value: `timerified ${fn.name}` - } + value: `timerified ${fn.name}`, + }, }); return timerified; diff --git a/lib/internal/perf/utils.js b/lib/internal/perf/utils.js index bcc7e223b8c882..a92e177e4246e9 100644 --- a/lib/internal/perf/utils.js +++ b/lib/internal/perf/utils.js @@ -29,5 +29,5 @@ function refreshTimeOrigin() { module.exports = { now, getMilestoneTimestamp, - refreshTimeOrigin + refreshTimeOrigin, };