Skip to content
This repository has been archived by the owner on Dec 28, 2020. It is now read-only.

lupas/vuetify-i18n-language-switcher-nuxt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vuetify-18n-Language-Switcher-Nuxt

Important: This package is just used for personal / test-purposes and not really meant for production or distribution (yet). If you plan to use it in your project, do so on your own risk. Feel free to use it though and suggest improvements :-)

Easily adds a language switcher to a Nuxt+Vuetify+I88n App similar to the one on Vuetifyjs.com

How to install?

npm i vuetify-i18n-language-switcher-nuxt

How to use in your project?

Import the component in any .vue file like so:

...
components: {
  VuetifyI18nLanguageSwitcherNuxt: () =>
    import('vuetify-i18n-language-switcher-nuxt')
}
...

Example Usage

HTML:

<VuetifyI18nLanguageSwitcherNuxt :languages="languages" />

Script:

export default {
  components: {
    VuetifyI18nLanguageSwitcherNuxt: () =>
      import('vuetify-i18n-language-switcher-nuxt')
  },
  data() {
    return {
      languages: [
        {
          id: 'en',
          title: 'English',
          flagSrc: 'https://cdn.vuetifyjs.com/images/flags/us.png'
        },
        {
          id: 'kr',
          title: 'Korean',
          flagSrc: 'https://cdn.vuetifyjs.com/images/flags/kr.png'
        }
      ]
    }
  }
}

About

Easily adds a language switcher to a Nuxt+Vuetify+I88n App similar to the one on Vuetifyjs.com

Resources

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published