[Hugo][Netlify] How can i add "last modified" line to my article if i edit the published posts with Netlify CMS?

Hi guys. I have a question

---
title: Hello World
date: 2022-01-21T10:58:19.597Z
summary: This is hello World
draft: false
---

As you can see i have an post with date: 2022-01-21T10:58:19.597Z ( 21-02-2022),
Let said i edited the content of the posts and deploy the latest version of my post content

Now i want to show the *last modified came with latest datetime. How can i do it?
image

Show the template that is creating the area in your code. Basically it’s a situation, where you check if you are in the first iteration of recent posts and use that date for the timestamp.

{{ range $index, $item := something }}
{{ if eq 0 $index }}
... you are in the first item, use `$item.Date` to format your last update stamp
{{ end }}
... do the rest of your loop to show a list with titles, like $item.Title
{{ end }}

@davidsneighbour Sorry i just corrected the question.
I create a article and publish the article with Netlify CMS. Now everytime i edit and re-push again. I want edited article show the last modified time . Like the below example
image

That’s something completely else :wink: I am not sure if Netlify CMS is updating the lastmod frontmatter. See that your posts AND your archetype for your posts have lastmod as a parameter within the frontmatter (like date). Then change the layout file that creates your metabyline to use .Lastmod instead of .Date.

If that is unclear… ehm… post your repo or layout :wink:

Here is a quick article that looks right: Last Modified Date in Hugo | Mert Bakır

But like I said… it might be that Netlify CMS is ignoring that field.