1 2 Date.prototype.isAprilFool = function(){ 3 return (this.getMonth() == 3 && this.getDate() == 1) 4 }
var now = new Date();
now.isAprilFool() // true or false
12970 users tagging and storing useful source code snippets
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
1 2 Date.prototype.isAprilFool = function(){ 3 return (this.getMonth() == 3 && this.getDate() == 1) 4 }
You need to create an account or log in to post comments to this site.