@m1mmseen
Posted
At first i struggled too on getting the right ages with the Date class. But i was not satisfied with all my tries :D Finally, I just subtracted the Date elements individually (day, month, year) because of the loose typing in js .In addition, I simply made queries that take care of the limit values (monthly and yearly transitions). I also calculated the months using a median. Please take a look at my code here on Github.
Marked as helpful
@Liberator-I
Posted
@m1mmseen Thank you very much! Going through your code helped me see what kind of approach you decided to take. Definitely gave me more insight on how I could have done a few things differently myself