MCPcopy
hub / github.com/NUKnightLab/TimelineJS3 / Floorer

Function Floorer

src/js/date/TLDate.js:467–472  ·  view source on GitHub ↗
(unit)

Source from the content-addressed store, hash-verified

465const EON = ERA * 10;
466
467function Floorer(unit) {
468 return function(a_big_year) {
469 var year = a_big_year.getTime();
470 return new BigYear(Math.floor(year / unit) * unit);
471 }
472}
473
474// cosmological scales
475export const BIG_DATE_SCALES = [ // ( name, units_per_tick, flooring function )

Callers

nothing calls this directly

Calls 1

getTimeMethod · 0.45

Tested by

no test coverage detected