Currently date diff returns the float diff values. But it's not easy to tell if two date are in the same year/month/day. Is there any better way to test it?
For example:
var d1 = new XDate(2013, 8, 1);
var d2 = new XDate(2012, 9, 1);
d1.diffYear(d2); // same year, so return 0;
d1.diffMonth(d2); // return 1
Knowing that you are focusing on fullcal, I take back my requirement. XDate is still a power full lib. Thank you very much.
Currently date diff returns the float diff values. But it's not easy to tell if two date are in the same year/month/day. Is there any better way to test it? For example: var d1 = new XDate(2013, 8, 1); var d2 = new XDate(2012, 9, 1); d1.diffYear(d2); // same year, so return 0; d1.diffMonth(d2); // return 1
Knowing that you are focusing on fullcal, I take back my requirement. XDate is still a power full lib. Thank you very much.