Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Date.prototype.addHours = (h) ->
date = new Date @
date.setHours @getHours() + h
date
Date.prototype.isWeekday= ->
weekdays = [1..5] # Javascript days are integers from 0-6 starting at Sunday
debugger
_.contains weekdays, @.getDay()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.