Update Date for 11ty file
In 11ty you can place metadata into a file using the
--- at the top of an article. It took me a while to understand how to do this in 11ty because they call this Front Matter Data. Anyway I was able to add some fields but the one I was interested in was adding an update date to my articles so I could latter either order my posts by the last updated date instead of just created as I will be updating content as I go along. Also I could for now just show this in my articles.
My other interest here is to be able to create posts but only show them in the lists based on this date and then the actual article will be "published" or go live on the date I had specified. So I have setup the Front Matter Data using the the YML setup described in the documentation:
--- title: Update Date for 11ty file description: Adding a field to show the last updated date of the article date: 2019-10-02 updated: 2019-10-02 layout: layouts/article.njk tags: - articles - vanilla js - 11ty navtitle: Update Date for 11ty file ---