aboutsummaryrefslogtreecommitdiff
path: root/src/lib.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib.ts')
-rw-r--r--src/lib.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib.ts b/src/lib.ts
index d9d5867..804e352 100644
--- a/src/lib.ts
+++ b/src/lib.ts
@@ -363,8 +363,10 @@ if (DEBUG){
}
}
}
-export function stepDate( // If stepping by month or years, leaves day value unchanged
+export function stepDate( // Steps a date N units along a scale
date: HistDate, scale: number, {forward=true, count=1, inplace=false} = {}): HistDate {
+ // If stepping by month or years, leaves day value unchanged
+ // Does not account for stepping a CalDate into before MIN_CAL_YEAR
const newDate = inplace ? date : date.clone();
if (count < 0){
count = -count;