Now, I’d like to display only upcoming events starting in the future.
I’m using something like this to only display eg “Some event”:
{{ $upcomingEvents := where $.Site.Data.events.Entries "date" "ge" now }}
This works when using toml, but for the life of me I cant seem to get the yaml date parsed in that where clause: $upcomingEvents will just be an empty array.
I tried things like this, but to no avail: {{ $upcomingEvents := where $.Site.Data.events.Entries (time "date") "ge" now }}
Somebody got a hint for me?
Fyi using time with a single yaml entry works nicely, so the input fmt seems ok.
[map[Title:Some event date:2018-09-11T15:20:15+09:100] map[Title:Some old event date:2017-09-11T15:20:15+09:100]]
So, date is a string. I can, however parse it as date just fine using the time function.
I only dont know how to do that inside of the where statement. Any ideas?