no message
Former-commit-id: 16c40bf6e935273762682ae61e5dc018ca85f49c Former-commit-id: 66e7c6205a0e5f854dedfa1ad88d571ee5597845 Former-commit-id: 44ff661db3da43bac73a68d6c523cd6e59aa9fa0
This commit is contained in:
32
src/pages/demo/plugins/vue-i18n/demo-1.vue
Normal file
32
src/pages/demo/plugins/vue-i18n/demo-1.vue
Normal file
@@ -0,0 +1,32 @@
|
||||
<template>
|
||||
<Container>
|
||||
<PageHeader
|
||||
slot="header"
|
||||
title="示例1"
|
||||
url="http://kazupon.github.io/vue-i18n/en/">
|
||||
</PageHeader>
|
||||
<div>
|
||||
<el-radio-group v-model="lang" @change="handleChange">
|
||||
<el-radio-button label="CN">中文</el-radio-button>
|
||||
<el-radio-button label="EN">English</el-radio-button>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<p>{{$t('message.hello')}}</p>
|
||||
</Container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
lang: 'CN'
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleChange (val) {
|
||||
this.$i18n.locale = val
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user