Skip to content

Instantly share code, notes, and snippets.

@black-black-cat
Created November 27, 2017 11:06
Show Gist options
  • Save black-black-cat/3475be75115577272fc6a588c7b490b8 to your computer and use it in GitHub Desktop.
Save black-black-cat/3475be75115577272fc6a588c7b490b8 to your computer and use it in GitHub Desktop.
获取一个月的最后一天
function getLastDate(y, m) { return new Date(m > 11 ? y + 1 : y, m % 12, 0) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment