Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/durationjs/src/duration.ts>default#reload

Get the formated time duration
Latest
method default.prototype.reload
import { default } from "https://deno.land/x/durationjs@v4.1.1/src/duration.ts";

Update data to match any modification to values.

Examples

Example 1

const d = new Duration(923431);
d.ms += 5;
d.s += 7;
console.log(d); // before update
d.reload();
console.log(d); // after update

Returns

Updated duration.