mirror of
https://github.com/jerryc127/hexo-theme-butterfly.git
synced 2026-04-10 21:17:07 +08:00
chore: 简化结构化数据配置,移除不必要的嵌套
This commit is contained in:
@@ -1025,8 +1025,7 @@ Open_Graph_meta:
|
|||||||
|
|
||||||
# Structured Data
|
# Structured Data
|
||||||
# https://developers.google.com/search/docs/guides/intro-structured-data
|
# https://developers.google.com/search/docs/guides/intro-structured-data
|
||||||
structured_data:
|
structured_data: true
|
||||||
enable: true
|
|
||||||
|
|
||||||
# Add the vendor prefixes to ensure compatibility
|
# Add the vendor prefixes to ensure compatibility
|
||||||
css_prefix: true
|
css_prefix: true
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
if theme.structured_data.enable && page.layout === 'post'
|
if theme.structured_data && page.layout === 'post'
|
||||||
-
|
-
|
||||||
// use json-ld to add structured data
|
// use json-ld to add structured data
|
||||||
|
|
||||||
|
|||||||
@@ -567,9 +567,7 @@ hexo.extend.filter.register('before_generate', () => {
|
|||||||
enable: true,
|
enable: true,
|
||||||
option: null
|
option: null
|
||||||
},
|
},
|
||||||
structured_data: {
|
structured_data: true,
|
||||||
enable: true
|
|
||||||
},
|
|
||||||
css_prefix: true,
|
css_prefix: true,
|
||||||
inject: {
|
inject: {
|
||||||
head: null,
|
head: null,
|
||||||
|
|||||||
Reference in New Issue
Block a user