@@ -26,7 +26,7 @@ use crate::helpers::parents::parents;
2626use crate :: helpers:: title:: page_title;
2727use crate :: pages:: json:: {
2828 BlogIndex , BuiltPage , CommonJsonData , ItemContainer , JsonBlogPostDoc , JsonBlogPostPage ,
29- JsonHomePage , JsonHomePageSPAHyData , JsonSpaPage ,
29+ JsonHomePage , JsonHomePageSPAHyData , JsonSpaPage , Parent ,
3030} ;
3131use crate :: pages:: page:: { Page , PageLike , PageReader } ;
3232use crate :: pages:: templates:: SpaBuildTemplate ;
@@ -139,7 +139,15 @@ impl SPA {
139139 } ) ,
140140 page_title : self . title ( ) . to_owned ( ) ,
141141 common : CommonJsonData {
142- parents : parents ( self ) ,
142+ // Blog index is paginated, with the page as a path parameter, for example
143+ // `/en-US/blog/4`.
144+ // To avoid duplicate parent entries generated by traversing the URL,
145+ // just return the single base blog URL. The single Breadcrumb will always
146+ // link to the first blog index page.
147+ parents : vec ! [ Parent {
148+ uri: "/en-US/blog/" . to_string( ) ,
149+ title: self . title( ) . to_owned( ) ,
150+ } ] ,
143151 ..Default :: default ( )
144152 } ,
145153 image : None ,
0 commit comments