Natural esm code splitting using dynamic import.
Change the language in browser to french/es/hi/ar/fr-ca to check this.
The main moment file needs to be added in src (like in current libs.js) and rest splitted files(locales) will be loaded dynamically.
with all locales bundled together :
import(moment/min/locales
);
With individual imports :
import(moment/locale/fr
);
each locale file will be dynamically imported.