webpack-i18n-fallbacks
TypeScript icon, indicating that this package has built-in type declarations

0.5.1 • Public • Published

webpack-i18n-fallbacks

Webpack plugin to be able to manage all translation files and their fallbacks in build time

new I18nPlugin(master_language, options)

master_language: master language options: hash with options

Options

path: path pointing to all translation files supportedLocales: list of all supported locales fallbacks: a hash with all the defined fallbacks

Example

new I18nPlugin('es', {
 path: 'src/translations',
 supportedLocales: ['es', 'ca', 'en', 'nl'],
 fallbacks: {
   ca: 'es',
   en: 'es',
   nl: 'en'
 }
})

Readme

Keywords

Package Sidebar

Install

npm i webpack-i18n-fallbacks

Weekly Downloads

9

Version

0.5.1

License

GPL-3.0

Unpacked Size

48.3 kB

Total Files

10

Last publish

Collaborators

  • masylum
  • fcsonline