MomentJs isAfter bug

On the app I’m managing and building at Warwick WMG I’ve come across a bit of a problem with momentjs and its isAfter method.

It never seems to correctly evaluate two times together and always returns `false` no matter what I pass through it.

So after lots of creative problem solving and searching I came across this jsfiddle article which gave me an alternative which is working.

Below is my solution.

 

 

Author: Dan Course

Dan Course, E-Learning Development at Warwick University (WMG). Agile Scrum trained and full-stack development. Interested in E-learning, Democracy, Politics and Tech. All thoughts are mine and not of my employer.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s