Skip to content

Commit

Permalink
docs: fix correct docs
Browse files Browse the repository at this point in the history
  • Loading branch information
soulgalore committed Feb 14, 2025
1 parent 719a6ad commit 89d4312
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions lib/core/engine/command/measure.js
Original file line number Diff line number Diff line change
Expand Up @@ -478,8 +478,9 @@ export class Measure {

/**
* Adds a custom metric to the current measurement result.
* This method should be called after a measurement has started and before it has stopped.
*
* The metric will be attached to the latest tested page, meaming
* you need to have measured a URL and stopped the measurement before
* you add the metric.
* @param {string} name - The name of the metric.
* @param {*} value - The value of the metric.
* @throws {Error} Throws an error if called before a measurement cycle has started.
Expand All @@ -497,7 +498,9 @@ export class Measure {
/**
* Adds multiple custom metrics to the current measurement result.
* This method accepts an object containing multiple key-value pairs representing different metrics.
* Similar to `add`, it should be used within an active measurement cycle.
* The metric will be attached to the latest tested page, meaming
* you need to have measured a URL and stopped the measurement before
* you add the metric.
*
* @param {Object} object - An object containing key-value pairs of metrics to add.
* @throws {Error} Throws an error if called before a measurement cycle has started.
Expand Down

0 comments on commit 89d4312

Please sign in to comment.