Skip to content

Instantly share code, notes, and snippets.

@edivandecastro
Created June 12, 2015 12:35
Show Gist options
  • Save edivandecastro/ece19de871b56fb61f55 to your computer and use it in GitHub Desktop.
Save edivandecastro/ece19de871b56fb61f55 to your computer and use it in GitHub Desktop.
get-first-and-last-date-of-current-month-with-javascript-or-jquery
var date = new Date();
var firstDay = new Date(date.getFullYear(), date.getMonth(), 1);
var lastDay = new Date(date.getFullYear(), date.getMonth() + 1, 0);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment