📅  最后修改于: 2022-03-11 15:03:46.498000             🧑  作者: Mango
代码示例1
const currentYear = new Date().getFullYear(); // 2020
const previousYear = currentYear-1;
console.log(previousYear); // 2019