MCPcopy Create free account
hub / github.com/chartjs/Chart.js / format

Method format

src/scales/scale.time.js:510–516  ·  view source on GitHub ↗

* @param {number} value * @param {string|undefined} format * @return {string}

(value, format)

Source from the content-addressed store, hash-verified

508 * @return {string}
509 */
510 format(value, format) {
511 const options = this.options;
512 const formats = options.time.displayFormats;
513 const unit = this._unit;
514 const fmt = format || formats[unit];
515 return this._adapter.format(value, fmt);
516 }
517
518 /**
519 * Function to format an individual tick mark

Callers

nothing calls this directly

Calls 1

formatMethod · 0.65

Tested by

no test coverage detected