Create a new Date instance to get the current date, use getFullYear to get the year from that, and create a Date intance with the year, month 0 (January), and date 1:
Date
getFullYear
var d = new Date(new Date().getFullYear(), 0, 1);
1.4m articles
1.4m replys
5 comments
57.0k users