Working with durations
This will sum the properties time_1
and time_2
:
```dataviewjs
let totalDuration = Duration.fromMillis(0)
totalDuration = totalDuration.plus(dv.current().time_1)
totalDuration = totalDuration.plus(dv.current().time_2)
dv.paragraph('Total time: ' + totalDuration.toFormat("h 'hours and' m 'minutes'"))
dv.paragraph('Total minutes: ' + totalDuration.as('minutes'))
```
Total time: 2 hours and 34 minutes
Total minutes: 154