vue-i18n-babelfish
Babelfish formatter for vue-i18n
Last updated 2 years ago by podkot .
MIT · Original npm · Tarball · package.json
$ cnpm install vue-i18n-babelfish 
SYNC missed versions from official npm registry.

???? vue-i18n-babelfish

nodeca/babelfish-based custom formatter for vue-i18n.

Installation:

yarn add vue-i18n-babelfish
# or
npm i vue-i18n-babelfish

Usage:

import Vue from 'vue';
import VueI18n from 'vue-i18n';
import BabelfishFormatter from 'vue-i18n-babelfish';
import App from './App.vue';

Vue.use( VueI18n );

const locale = 'ru';

const formatter = new BabelfishFormatter( {
    locale,
    fallbacks : {
        'uk': 'ru',
    },
} );

const i18n = new VueI18n( {
    locale,
    formatter,
    messages : {},
} );

// eslint-disable-next-line no-new
new Vue( {
    i18n,
    el     : '#app',
    render : h => h( App ),
} );

Example folder of the project contains webpack-powered example, using regru/dict-loader.

Current Tags

  • 1.0.1                                ...           latest (2 years ago)

2 Versions

  • 1.0.1                                ...           2 years ago
  • 1.0.0                                ...           3 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 2
Last Day 0
Last Week 1
Last Month 1
Dependencies (1)
Dev Dependencies (3)
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |