Cleaned up client-side JS and made Moment work again.