Skip to content

Instantly share code, notes, and snippets.

@Konafets
Created October 14, 2017 17:34
Show Gist options
  • Save Konafets/495b128900f90deeac87358862b24c58 to your computer and use it in GitHub Desktop.
Save Konafets/495b128900f90deeac87358862b24c58 to your computer and use it in GitHub Desktop.
Setup vuex-i18n
import store from './vuex';
import vuexI18n from 'vuex-i18n';
Vue.use(vuexI18n.plugin, store);
import Locales from './vue-i18n-locales.generated.js';
Vue.i18n.add('en', Locales.en);
Vue.i18n.add('de', Locales.de);
// set the start locale to use
Vue.i18n.set('en');
const app = new Vue({
store,
el: '#app',
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment