Date.getFirstDateOfMonth

Syntax

PP.Date.getFirstDateOfMonth(date): Date;

Parameters

date. Date. Date.

Description

The getFirstDateOfMonth static method returns the month first day date.

Comments

The method returns an object of the Date type.

Example

To execute the example, add a link to PP.js scenario file to HTML page.

// Create the current date
date = new Date();
// Get the month first day date
newDate = PP.Date.getFirstDateOfMonth(date);
console.log(newDate);

After executing the example the month first day date is obtained.

See also:

PP