mirror of
				https://github.com/Wonderfall/hugo-WonderMod.git
				synced 2025-10-30 03:15:26 +01:00 
			
		
		
		
	layouts: Add DateFormat parameter (#39)
* User can change Date Format to be displayed in Front Matter * Formats supported by Hugo can be found here: https://gohugo.io/functions/format/#hugo-date-and-time-templating-reference
This commit is contained in:
		| @@ -8,7 +8,7 @@ | ||||
|     </h1> | ||||
|     {{- if .Params.hideMeta }}{{ else }} | ||||
|     <div class="post-meta"> | ||||
|       <time>{{ .Date.Format "January 2, 2006" }}</time> | ||||
|       <time>{{ .Date.Format (default "January 2, 2006" .Site.Params.DateFormat) }}</time> | ||||
|       {{- if $.Site.Params.ShowReadingTime -}} ·  | ||||
|       {{- $default_txt := print .ReadingTime " " "min" }} | ||||
|       {{- i18n "read_time" .ReadingTime | default  $default_txt  }}{{ end }} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Northerner-coder
					Northerner-coder