const today = new Date();
const quarter = Math.floor((today.getMonth() / 3));
const startFullQuarter = new Date(today.getFullYear(), quarter * 3, 1);
const endFullQuarter = new Date(startFullQuarter.getFullYear(), startFullQuarter.getMonth() + 3, 0);
const daysOfQuarter = Math.round((endFullQuarter - startFullQuarter)/(1000*60*60*24));