Skip to content

Commit 717fe4a

Browse files
committed
fix toc wrong typing
1 parent 142c14c commit 717fe4a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contentlayer.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ const computedFields: ComputedFields = {
5454
type: 'string',
5555
resolve: (doc) => doc._raw.sourceFilePath,
5656
},
57-
toc: { type: 'string', resolve: (doc) => extractTocHeadings(doc.body.raw) },
57+
toc: { type: 'json', resolve: (doc) => extractTocHeadings(doc.body.raw) },
5858
}
5959

6060
/**

0 commit comments

Comments
 (0)