Very impressive setup in the config.toml didn’t even know some of these options existed.
so basically I can range the same way I range for cards and use a template like this
[
{{ $allPages := where .Site.RegularPages "Section" "properties-for-sale" }}
{{ $sortedPages := sort $allPages ".Params.title" "desc" }}
{{- range $sortedPages -}}
{
"title": "{{ .Title }}",
"date": "{{ .Date }}",
"content": "{{ .Content }}"
}{{ if not (last $sortedPages) }},{{ end }}
{{- end -}}
]
Now in your example home.json.json template in default generate .json file for home page. but in my option where I want to use it for a section such as
Should I place the json template in layouts/properties-for-sale/default.json.json or name it properties-for-sale.json.json in the _default directory
Thanks
The Main issue
The main issue is the json file generates the same time as the cards are generated. I want the json to generate after the card generation so it can get the image url required for the card display etc.