mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-29 22:29:56 +02:00
Add render template hooks for links and images
This commit also * revises the change detection for templates used by content files in server mode. * Adds a Page.RenderString method Fixes #6545 Fixes #4663 Closes #6043
This commit is contained in:
@@ -358,16 +358,6 @@ func (c *PageCollections) removePage(page *pageState) {
|
||||
}
|
||||
}
|
||||
|
||||
func (c *PageCollections) findPagesByShortcode(shortcode string) page.Pages {
|
||||
var pages page.Pages
|
||||
for _, p := range c.rawAllPages {
|
||||
if p.HasShortcode(shortcode) {
|
||||
pages = append(pages, p)
|
||||
}
|
||||
}
|
||||
return pages
|
||||
}
|
||||
|
||||
func (c *PageCollections) replacePage(page *pageState) {
|
||||
// will find existing page that matches filepath and remove it
|
||||
c.removePage(page)
|
||||
|
Reference in New Issue
Block a user