I found a shortcode at some point , that lets me include partials into a markdown file:
{{ partial (.Get 0) . }}
I’m currently using it for a project list. The TL;DR: is just that it’s an HTML partial with some divs and some text. The relevant portion of my markdown file is then just:
# Projects
{{< mdpartial "projects.html" >}}
Now, if I make and write changes to projects.html
, the site reloads. However, no changes are made to the resulting index.html
.
The actual problem here is that if I make changes to the partial, the markdown file that includes it isn’t updated. If I make changes to the markdown file, or even the config, it rebuilds and works fine.
Is this a bug, or is there some “secret” option somewhere that makes rebuilding work as expected here? I tried with --disableFastrender
, but updates still aren’t reflected.
Also, this isn’t like SCSS (… which of course started working when I updated to 0.87 and asked a question using it as an example) where changes don’t result in a reload even though the changes are committed - I need to change another file or do a complete rebuild to see the changes I’ve made reflected. This caused some confusion with where the “fault” lied earlier, when I made changes to display a variable I’ve defined in my config, but it didn’t actually display. The site reloaded, so I assumed the changes were properly made, but turns out no updates are made to the file generated from the markdown file - at all. Doesn’t matter if I manually reload the website, I need an entire manual rebuild or to update an applicable file for it to display properly. (this largely just means nudging the timestamp to trick hugo into thinking it’s dirty)