File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -691,7 +691,7 @@ function getReactionEmoji(reaction: string) {
691691 data-repo-id = " R_kgDOLTuIuQ"
692692 data-category = " General"
693693 data-category-id = " DIC_kwDOLTuIuc4Csz7O"
694- data-mapping = " og:title "
694+ data-mapping = " pathname "
695695 data-strict = " 0"
696696 data-reactions-enabled = " 1"
697697 data-input-position = " top"
Original file line number Diff line number Diff line change @@ -265,6 +265,21 @@ async function main() {
265265 `Successfully wrote ${ structuredComments . length } structured discussions to src/data/comments-structured.json`
266266 )
267267
268+ // --- DEBUG: Log bodyHTML for comments with code blocks ---
269+ const commentsWithCode = allComments . filter ( comment => comment . bodyHTML . includes ( '<pre><code' ) ) ;
270+ if ( commentsWithCode . length > 0 ) {
271+ console . log ( '\n--- bodyHTML for comments with code blocks ---' ) ;
272+ commentsWithCode . forEach ( ( comment , index ) => {
273+ console . log ( `\nComment ID: ${ comment . id } ` ) ;
274+ console . log ( `Author: ${ comment . author . login } ` ) ;
275+ console . log ( `bodyHTML:\n${ comment . bodyHTML } ` ) ;
276+ } ) ;
277+ console . log ( '--------------------------------------------\n' ) ;
278+ } else {
279+ console . log ( '\nNo comments with code blocks found in fetched data.\n' ) ;
280+ }
281+ // --- END DEBUG ---
282+
268283 // 输出统计信息
269284 const stats = {
270285 totalDiscussions : discussions . length ,
You can’t perform that action at this time.
0 commit comments