prevDayOfWeek

A function which returns a date by a specific week name. For example, Day.Monday.

prevDayOfWeek(new Date(2016, 0, 1), Day.Wednesday); // 2015-12-30, Wednesday

Parameters

date Date

The date to calculate from.

weekDay Day

The Day enum specifying the desired week day.

Returns

Date - A Date instance.

 /