fix: injection of frontmatter.head fails when it does not exist
This commit is contained in:
parent
98d641ee52
commit
e14b1a8bf1
@ -8,6 +8,7 @@ export const baiduTongjiPlugin = ({ key = '' }: BaiduTongjiOptions): Plugin => {
|
||||
return {
|
||||
name: '@vuepress-plume/vuepress-plugin-baidu-tongji',
|
||||
extendsPage: (page) => {
|
||||
page.frontmatter.head = page.frontmatter.head || [];
|
||||
page.frontmatter.head?.push([
|
||||
'script',
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user