npm install --save vue-chrome-i18n
# OR
yarn add vue-chrome-i18n
git clone https://github.com/Xvezda/vue-chrome-i18n.git
cd vue-chrome-i18n
yarn install
yarn run build # dist/vue-chrome-i18n.js
<script src=".../vue.js"></script>
<script src=".../vue-chrome-i18n.js"></script>
<script>
Vue.use(VueChromeI18n); // Install plugin
</script>
then
<vue-chrome-i18n>__MSG_messagename__</vue-chrome-i18n>
or
<a href="..." target="_blank" v-chrome-i18n>__MSG_messagename__</a>
or
<div>{{ 'messagename' | chrome-i18n }}</div>
Attribute | Description | Type | Default |
---|---|---|---|
show | Set visibility | Boolean | true |
nl2br | Replace linefeeds to <br> tags |
Boolean | false |