diff --git a/content/flux/v0.x/stdlib/date/add.md b/content/flux/v0.x/stdlib/date/add.md index 9562ef114..973daf239 100644 --- a/content/flux/v0.x/stdlib/date/add.md +++ b/content/flux/v0.x/stdlib/date/add.md @@ -1,10 +1,10 @@ --- -title: date.addDuration() function +title: date.add() function description: > - `date.addDuration()` adds a duration to a time value and returns the resulting time. + `date.add()` adds a duration to a time value and returns the resulting time. menu: flux_0_x_ref: - name: date.addDuration + name: date.add parent: date weight: 302 flux/v0.x/tags: [date/time] @@ -15,12 +15,12 @@ related: introduced: 0.162.0 --- -`date.addDuration()` adds a duration to a time value and returns the resulting time. +`date.add()` adds a duration to a time value and returns the resulting time. ```js import "date" -date.addDuration(d: 12h, to: now()) +date.add(d: 12h, to: now()) ``` ## Parameters @@ -39,7 +39,7 @@ Durations are relative to [`now()`](/flux/v0.x/stdlib/universe/now/). ```js import "date" -date.addDuration(d: 6h, to: 2019-09-16T12:00:00Z) +date.add(d: 6h, to: 2019-09-16T12:00:00Z) // Returns 2019-09-16T18:00:00.000000000Z ``` @@ -50,7 +50,7 @@ import "date" option now = () => 2022-01-01T12:00:00Z -date.addDuration(d: 6h, to: 3h) +date.add(d: 6h, to: 3h) // Returns 2022-01-01T21:00:00.000000000Z ``` diff --git a/content/flux/v0.x/stdlib/date/sub.md b/content/flux/v0.x/stdlib/date/sub.md index 29a5f25ad..79ca1ad9f 100644 --- a/content/flux/v0.x/stdlib/date/sub.md +++ b/content/flux/v0.x/stdlib/date/sub.md @@ -1,11 +1,11 @@ --- -title: date.subDuration() function +title: date.sub() function description: > - `date.subDuration()` subtracts a duration from a time value and returns the + `date.sub()` subtracts a duration from a time value and returns the resulting time value. menu: flux_0_x_ref: - name: date.subDuration + name: date.sub parent: date weight: 302 flux/v0.x/tags: [date/time] @@ -16,13 +16,13 @@ related: introduced: 0.162.0 --- -`date.subDuration()` subtracts a duration from a time value and returns the +`date.sub()` subtracts a duration from a time value and returns the resulting time value. ```js import "date" -date.subDuration(d: 12h, from: now()) +date.sub(d: 12h, from: now()) ``` ## Parameters @@ -41,7 +41,7 @@ Durations are relative to [`now()`](/flux/v0.x/stdlib/universe/now/). ```js import "date" -date.subDuration(d: 6h, from: 2019-09-16T12:00:00Z) +date.sub(d: 6h, from: 2019-09-16T12:00:00Z) // Returns 2019-09-16T06:00:00.000000000Z ``` @@ -52,7 +52,7 @@ import "date" option now = () => 2022-01-01T12:00:00Z -date.subDuration(d: 6h, from: -3h) +date.sub(d: 6h, from: -3h) // Returns 2022-01-01T03:00:00.000000000Z ```