Date Add and Subtract is a sample add-on for Google Sheets that provides custom functions for date manipulation. The script uses the Moment.js JavaScript library, which is included directly in the Apps Script project.
For your convience we have published the script to the Google Sheets add-ons store. Install the add-on via the store and follow the instructions to get started.