getMonth
월을 반환합니다 (0~11, 0이 1월).
date.getMonth()
아래 값을 입력하면 예제에 즉시 반영됩니다.
const
new
June
console
Jan
Jun
const date = new Date(2024, 5, 15); // June 15 console.log(date.getMonth()); // 5 (0=Jan, 5=Jun)