Date Filters

You are here:

Date Filters

These date filters allow you to modify the formating of dates in some pretty cool ways!

Now! When working with dates you'll often want to get the current date/time. This is possible with the 'Now' keyword. You can use in places where you'd normally input a date/time to use the current date/time. Consider the example below which would display today's date like '12/19/2018'.
{{ 'Now' | Date:'M/d/yyyy' }}
 

Date

Show Details
v1.0

Displays the date given a format string. The string 'Now' can be used for the current date/time.

 

DateAdd

Show Details
v4.0

Adds a span of time to a provided date (default is in days).

 

DateDiff

Show Details
v1.0

Takes two datetimes and returns the difference in the unit you provide. You can provide the value 'Now' for either the start or end date.

 

DatesFromICal

Show Details
v4.0

Returns a list of upcoming dates from an iCal string or List of iCal strings.

 

DaysFromNow

Show Details
v4.0

Returns a humanized string of the number of days from now without concern for time.

 

DaysInMonth

Show Details
v7.0

Returns the number of days in the month you provide.

 

DaysSince

Show Details
v8.0

Returns the number of days have past since a given date.

 

DaysUntil

Show Details
v8.0

Returns the number of days from now.

 

HumanizeDateTime

Show Details
v1.0

Compares the provided date/time to the current date/time and returns a human friendly string like 'yesterday' or '2 hours ago'.

 

HumanizeTimeSpan

Show Details
v1.0

Takes two datetimes and humanizes the difference like '1 day'. Supports 'Now' in either the start or end date.

 

NextDayOfTheWeek

Show Details
v8.0

Advances the date to a specific day in the next 7 days.

 

SundayDate

Show Details
v5.0

Returns the Sunday date of the date provided.

 

ToMidnight

Show Details
v8.0

Sets the time to midnight for a specific day.