hapi-react-starter-kit
hapi-react-starter-kit copied to clipboard
Bug in localeReducer.js
The import statements in the localReducer.js is generating an error.
The folder structure for react-intl changed.
The following section:
import en from 'react-intl/lib/locale-data/en';
import es from 'react-intl/lib/locale-data/es';
needs to be updated to:
import en from 'react-intl/locale-data/en';
import es from 'react-intl/locale-data/es';
because the locale-data is no longer in the lib folder, it is located at the root level of the project.
Yes, that will be in next update. We are still using an old version of react-intl. Thanks for pointing it out. We should also get those files dinamically and not as constants. So more languages can be added without having to alter localeReducer.js file.
Workaround:
Remove the following lines
import en from 'react-intl/lib/locale-data/en'; import es from 'react-intl/lib/locale-data/es';
Additionally remove references to en / es in the same file.