You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
397 B
15 lines
397 B
import interval from "./interval"; |
|
import {durationDay} from "./duration"; |
|
|
|
var utcDay = interval(function(date) { |
|
date.setUTCHours(0, 0, 0, 0); |
|
}, function(date, step) { |
|
date.setUTCDate(date.getUTCDate() + step); |
|
}, function(start, end) { |
|
return (end - start) / durationDay; |
|
}, function(date) { |
|
return date.getUTCDate() - 1; |
|
}); |
|
|
|
export default utcDay; |
|
export var utcDays = utcDay.range;
|
|
|