
How I cut my Webpack bundle size in half - celerity
http://jmduke.com/posts/how-i-cut-my-webpack-bundle-size-in-half/
======
anonova
In regards to date management, has anyone ever replaced moment with date-fns:
[https://date-fns.org/](https://date-fns.org/) ? It seems to be the lodash for
dates, in which you can do selective imports.

~~~
WorldMaker
As a further alternative, I keep wondering what's left to further standardize
towards Intl.DateTimeFormat [1][2] to leave it to the browsers to know the
local locale?

I suppose for me and my projects perhaps the biggest usages of Moment are
actually for the "humanizing" formats time until/time since (the things like
"20 minutes ago"/"3 days from now"). The locale data for those likely may
never be standardized into Intl. (~I also don't see equivalents of those
functions in a quick skim of date-fns docs, fwiw.~ ETA: Of course I spot it
soon after posting the comment; formatDistance)

[1] [https://developer.mozilla.org/en-
US/docs/Web/JavaScript/Refe...](https://developer.mozilla.org/en-
US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat)

[2] [http://caniuse.com/#search=intl](http://caniuse.com/#search=intl)

