1.0.13 • Published 4 years ago

vue-lang-code-flags v1.0.13

Weekly downloads
170
License
ISC
Repository
github
Last release
4 years ago

Flags by language codes

Vue component which shows the flag of the country from which the language comes from

How to install

Get the package from NPM:

npm install vue-lang-code-flags --save
or
yarn add vue-lang-code-flags --save

How to use

Register LangFlag component in your app. You can use two approaches:

  • in main.js you can mount it as a global Vue component:
import Vue from 'vue';
import LangFlag from 'vue-lang-code-flags';

Vue.component('lang-flag', LangFlag);
  • in a specific component (e.g.: Component.vue):
import LangFlag from 'vue-lang-code-flags';

new Vue({
  components: {
    LangFlag,
  },
});

Then, after the proper mounting, in your template you can call it like this:

<lang-flag iso="en" />
<lang-flag iso="ja" squared="false" />
<lang-flag iso="zh" title="Some title" />

API

Mandatory properties

PropertyDescriptionTypeValue
isoISO 639-1 identifier of the languageStringone of the values defined here

Optional properties

PropertyDescriptionTypeDefault
squaredSquared flagBooleantrue
titleTitleStringnull

Available Flags

Here follows the list of the currently available flags. They are identified using the ISO 639-1 standard.

LanguageCode
Arabicar
Armenianam
Azerbaijaniaz
Belarusianbe
Bengalibn
Bulgarianbg
Chinesezh
Catalanca
Czechcs
Englishen
Estonianet
Frenchfr
Germande
Hausaha
Hindihi
Hungarianhu
Italianit
Japaneseja
Javanesejv
Khmerkm
Koreanko
Latvianlv
Malayms
Marathimr
Persianfa
Polishpl
Portuguesept
Romanianro
Russianru
Spanishes
Swahilisw
Tamilta
Telugute
Thaith
Turkishtr
Uzbekuz
Vietnamesevi

Contributing

Please follow the guidelines here.

1.0.13

4 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago