feat: support blog favicon configuation, also can use online image or default favicon

This commit is contained in:
imesong
2023-07-23 17:32:42 +08:00
parent 4ed9b87981
commit e0f30f18f5
2 changed files with 2 additions and 1 deletions

View File

@@ -34,6 +34,7 @@ const BLOG = {
NOTION_HOST: process.env.NEXT_PUBLIC_NOTION_HOST || 'https://www.notion.so', // Notion域名您可以选择用自己的域名进行反向代理如果不懂得什么是反向代理请勿修改此项
BLOG_FAVICON: process.env.NEXT_PUBLIC_FAVICON || '/favicon.ico', // blog favicon 配置, 默认使用 /public/favicon.ico支持在线图片如 https://img.imesong.com/favicon.png
// 网站字体
FONT_STYLE: process.env.NEXT_PUBLIC_FONT_STYLE || 'font-sans', // ['font-serif','font-sans'] 两种可选,分别是衬线和无衬线: 参考 https://www.jianshu.com/p/55e410bd2115
FONT_URL: [

View File

@@ -13,7 +13,7 @@ class MyDocument extends Document {
return (
<Html lang={BLOG.LANG}>
<Head>
<link rel='icon' href='/favicon.ico' />
<link rel='icon' href= {`${BLOG.BLOG_FAVICON}`} />
<CommonScript />
</Head>