diff options
author | Alejandro <alex.mac.fon@gmail.com> | 2024-07-31 17:25:22 -0600 |
---|---|---|
committer | Alejandro <alex.mac.fon@gmail.com> | 2024-07-31 17:25:22 -0600 |
commit | f2e0eaaca8fad98f07d290a5c0ef9b160b8c1688 (patch) | |
tree | e8edb370aef206eee45a331703f657cf31f9938b /layouts/shortcodes | |
parent | 20b51e32ea8ebe331213c6de45edd452741a2267 (diff) |
added: shortcode for listing news
Diffstat (limited to 'layouts/shortcodes')
-rw-r--r-- | layouts/shortcodes/list-noticias.html | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/layouts/shortcodes/list-noticias.html b/layouts/shortcodes/list-noticias.html new file mode 100644 index 0000000..f1ce843 --- /dev/null +++ b/layouts/shortcodes/list-noticias.html @@ -0,0 +1,8 @@ +<ul class="news"> +{{ $p := where site.Pages "Params.tags" "intersect" (slice "noticia") }} +{{ range $p }} + +<li> <a href="{{.RelPermalink}}"> {{- if .Param "datesinlist" }}<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Date.Format "2006 Jan 02" }}</time> – {{ end -}} {{.Title}}</a></li> + +{{ end }} +</ul> |