feat: i18n,add en and zh-cn language.

This commit is contained in:
ex_zhangwenlei@exiot.cmcc
2024-11-22 14:53:36 +08:00
parent 8e6eff54f4
commit 391142223f
18 changed files with 189 additions and 116 deletions

View File

@@ -1,10 +1,11 @@
<script setup lang='ts'>
import {ref,onMounted} from 'vue'
import markdownit from 'markdown-it'
import i18n from '@/locales/i18n'
const md = markdownit()
const readmeHtml=ref('')
const readMd=()=>{
fetch('/log-lottery/readme.md')
fetch('/log-lottery/'+i18n.global.t('data.readmeName'))
.then(res=>res.text())
.then(res=>{
readmeHtml.value = md.render(res)