today

Gives the timestamp of the start of today (midnight) in the app's timezone. Compare dates with it: `date_diff(today(), due_at, "day")`.

Runs on: either side: the compiler places the statement that calls it where the values it uses live.

Format:

today()

Parameters:

This function does not take any parameters.

Returned Value:

Type Description
number the UNIX timestamp of midnight today

Examples

days_left = date_diff(today(), event.starts_at, "day")