wgl-holidays
v3.1.1
Published
Determines whether or not a particular day is one of:
Downloads
6
Maintainers
Keywords
Readme
Holidays
Determines whether or not a particular day is one of:
- New Year’s Day
- Thanksgiving
- Christmas
- Labor Day
- Memorial Day
- Independence Day
If New Year’s, Independence Day, or Christmas falls on a weekend, the closest weekday will also be included. For example, if Christmas is on a Saturday, the preceding Friday is considered a holiday. If it is on a Sunday, then the following Monday is a holiday.
Usage
var moment = require('moment');
var Holidays = require('wgl-holidays');
Holidays.isHoliday(moment(new Date()));