mysociety / nature-emergency

0 stars 0 forks source link

List of councils and nature emergency declarations #2

Open zarino opened 5 months ago

zarino commented 5 months ago

Simple list on homepage, showing council name, and declaration data.

Here’s the datapoints CE UK are collecting about each council, which we can choose from:

Need to decide whether to use Collections or Data files to represent councils.

Use provisional data for now, if CE UK’s data collection hasn’t finished by the time we start this ticket.

zarino commented 4 months ago

I was thinking, yesterday, about how we’ll want to store councils in the site – as a collection, or a data file.

Since we’ll eventually want Jekyll to generate a page per council (#9) that would seem to lead us to implementing them as a collection – but we probably don’t want to have to create a separate .md file per council. It may be easiest to implement them as a rows in a data file, and then add a plugin like jekyll-data-pages or jekyll-datapage_gen to output a page per row.

If we go down the data file + plugin route, then we’ll need to use a custom Github Actions build action (rather than the classic Github Pages flow) to generate the site on deploy. Example Github Actions workflow here, or a (non-Jekyll) example from FixMyStreet here.

A handful of other static site generators have out-of-the-box support generating pages from rows of data (programmatic generation in Gatsby, dynamic pages in Middleman), but they’d still require us to define our own custom Github Actions workflow to build the site, and my instinct is that it’ll be easier for us / Woodland Trust to find front-end devs who know Jekyll, in future, than all the other more specialised site generators.