vue-wechat-title
生活随笔
收集整理的這篇文章主要介紹了
vue-wechat-title
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
html中的title
安裝:npm install vue-wechat-title --save
1.在mian.js中
//網頁title
import VueTitle from 'vue-wechat-title'
Vue.use(VueTitle);
2. 路由中加下 title
{
path: '/',
component: Index,
meta: {
title: '首頁'
}
}
3. 在app.vue 中修改 router-view ,加入他的這個組件
<div id="app" v-wechat-title="$route.meta.title">
<router-view name="Head"></router-view>
<router-view name="Main"></router-view>
<router-view name="Foot"></router-view>
</div>
本文轉載于:猿2048?https://www.mk2048.com/blog/blog.php?id=0k1ihbb&title=vue-wechat-title
總結
以上是生活随笔為你收集整理的vue-wechat-title的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: HTML/CSS基础知识(四)
- 下一篇: 01-HTML深入