Is it possible to use Docpad as static site generator that also outputs json files that can be consumed by client side JS apps?
I'm building a website using Docpad as a static site generator, and I have an events section, where I want the events homepage to list all the events that are published using Docpad (with a link to the event details page).
What I'm trying to do is to generate the event lists by looping through a Collection that has all the events in it, but I also want to make the list more interactive and sortable (as we have a variety of events and want to make it easy for people to find events that are of interest).
What I would like to do is have the events list output to a JSON file, which we can pass to an AngularJS app which does the presentation,sorting and display of the events.
I know that Docpad can be used to generate an xml, but is possible to use Docpad to generate a json file with the data needed? So far my attempts are failing, which is why I'm asking if what I'm asking is even possible. My backup is to use XML, but I'd prefer JSON as Angular can consume it natively.
TIA.