{{$pathParts := splitList "/" .OriginalReq.URL.Path -}} {{$markdownFilename := default "index" (slice $pathParts 2 | join "/") -}} {{$markdownFilePath := printf "/ytring/%s.md" $markdownFilename -}} {{ if not (fileExists $markdownFilePath)}}{{httpError 404 }}{{end }} {{$markdownFile := (include $markdownFilePath | splitFrontMatter) -}} {{$title := default $markdownFilename $markdownFile.Meta.Title -}} {{$date := default "" $markdownFile.Meta.Date -}} {{$author := default "-" $markdownFile.Meta.Author -}} {{$lang := default "en" $markdownFile.Meta.Lang -}}
by {{$author}}
{{$date | date "2006-01-02"}}