Date.prototype.getFullYear

Returns the year, using local time.

Syntax

getFullYear()

Return value

A number representing the year.