Skip to content

Commit f5a4679

Browse files
authored
fix: disable title extraction when contentHeading === false (#3725)
1 parent 89c0b25 commit f5a4679

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/utils/content/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,9 @@ export async function createParser(collection: ResolvedCollection, nuxt?: Nuxt)
173173
transformers: extraTransformers,
174174
markdown: {
175175
...beforeParseCtx.parserOptions?.markdown,
176-
contentHeading: !file?.collectionType || file?.collectionType === 'page',
176+
contentHeading: beforeParseCtx.parserOptions?.markdown?.contentHeading === false
177+
? false
178+
: (!file?.collectionType || file?.collectionType === 'page'),
177179
},
178180
})
179181

0 commit comments

Comments
 (0)