new date get year js code example
Example 1: Javascript get current year
var currentYear= new Date().getFullYear();
Example 2: JS date year
var d = new Date();
var n = d.getFullYear();
var currentYear= new Date().getFullYear();
var d = new Date();
var n = d.getFullYear();