您的位置:首頁技術文章
文章詳情頁

Vue 修改網站圖標的方法

瀏覽:73日期:2022-10-13 18:22:32
1、在stateic下新增favicon.ico文件

Vue 修改網站圖標的方法

2、修改index.html文件,如圖

Vue 修改網站圖標的方法

<!DOCTYPE html><html> <head> <meta charset='utf-8'> <meta name='viewport' content='width=device-width,initial-scale=1.0'> <link rel='icon' type='image/x-icon' href='http://www.wxshucaidpc.com/bcjs/static/favicon.ico' rel='external nofollow' > <title>網站名稱</title> </head> <body> <div id='app'></div> <!-- built files will be auto injected --> </body></html>3、如果有新開頁面無法顯示圖標問題,修改bulid下的webpack.dev.conf.js文件

Vue 修改網站圖標的方法

Vue 修改網站圖標的方法

new HtmlWebpackPlugin({ filename: ’index.html’, template: ’index.html’, inject: true, favicon:’static/favicon.ico’//新增 }),4、這個時候再重新啟動一次項目就好啦

以上就是Vue 修改網站圖標的方法的詳細內容,更多關于Vue 修改網站圖標的資料請關注好吧啦網其它相關文章!

標簽: Vue
相關文章:
国产综合久久一区二区三区