提交 bf997d63 编写于 作者: EvanOne(文一)'s avatar EvanOne(文一)

feat: Add canonical setting

上级 19b81fa9
......@@ -13,6 +13,11 @@ shake_file: true
# Remember to set up your site-subtitle in Hexo `_config.yml`.
index_subtitle: false
# Set a canonical link tag for your Hexo site.
# See: https://support.google.com/webmasters/answer/139066
# Remember to set up your URL in Hexo `_config.yml` (e.g. url: http://yoursite.com)
canonical: true
# Webmaster tools verification setting
# ---------------------------------------------------------------
# Google Webmaster tools verification setting
......
......@@ -65,6 +65,9 @@ if theme.favicon.msapplication
meta(name="msapplication-TileImage" content=`${url_for(theme.favicon.msapplication)}`)
meta(name="msapplication-TileColor" content="#000000")
if theme.canonical
link(ref="canonical" href=full_url_for(page.path))
if _.get(theme, 'feed.rss')
link(rel="alternate" href=url_for(theme.feed.rss) type="application/atom+xml")
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册