I am working on a React / Webpack / Globalize application. In development mode, everything is fine (although Globalize insists on compiling all the locales, not on what I chose, but on a different question the other day).
However, when I set production: true in my webpack configuration, I get the following error when starting npm run build
> webpack --config webpack.prod.config.js /opt/app/ui/node_modules/globalize-webpack-plugin/GlobalizeCompilerHelper.js:72 throw e; ^ Error: No formatters or parsers has been provided
I was impressed that the globalize webpack plugin is designed to handle precompilation. Any idea why I see this error? When I set production: false , everything compiles fine.
My plugin setup:
new GlobalizePlugin({ production: true, developmentLocale: "en", supportedLocales: [ "en"], output: "i18n/[locale].[hash].js" }),
When the file changes and rebuilds the webpack dev servers, I get a lot of messages indicating that the locales are repeating, which I do not use:
[461] ./~/cldr-data/main/es-PY/dateFields.json 15 kB {0} [optional] [462] ./~/cldr-data/main/es-SV/dateFields.json 15 kB {0} [optional] [463] ./~/cldr-data/main/es-US/dateFields.json 15 kB {0} [optional] [464] ./~/cldr-data/main/es-UY/dateFields.json 15 kB {0} [optional] [465] ./~/cldr-data/main/es-VE/dateFields.json 15 kB {0} [optional] [466] ./~/cldr-data/main/es/dateFields.json 15 kB {0} [optional]
Nothing I try seems to get this problem.
Thanks
Harel
source share