Code Monkey home page Code Monkey logo

govuk-services-list's Introduction

UK Government digital services

A community-maintained list of digital services from the UK government.

Data sources

Previous data sources

How to run this project

You’ll need

  1. Node 20
  2. NPM

Using a command line run

npm install
npm start

How to add or update screenshots

Screenshots for service landing or home pages can be added automatically by running a script.

First, you need to have the latest version of Google Chrome installed.

To tell the script where the Google Chrome executable is located on your computer, create a file named .env (in the same folder as this README.md file) and add this named environment variable:

GOOGLE_CHROME_PATH=""

For example, on a Mac, this may be something like this:

GOOGLE_CHROME_PATH="/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"

Once this is set up, you can run the script to add the screenshots using this command:

npm run screenshots register-to-vote

Substitute register-to-vote with the name of the file for the service you want to screenshot.

You can also update all the screenshots (which will take a while) by running this command:

npm run screenshots all

Screenshots will be saved in the app/assets/images/service-screenshots folder, using the same name as the json file within app/services. Images are all 2160×2160 pixels (1080x1080 at 2× resolution), and will be rendered with no cookies set (so will include any cookie banner).

govuk-services-list's People

Contributors

colinbruce avatar davidsoff avatar dependabot[bot] avatar emollett avatar frankieroberto avatar htmlandbacon avatar jamietanna avatar jonodrew avatar matthewford avatar nickcolley avatar paulrobertlloyd avatar peterkwells avatar querkmachine avatar saliceti avatar sanjaypoyzer avatar simonneb avatar surminus avatar techforevil avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

govuk-services-list's Issues

New Feature: Filter By Service Lifecycle

Would it be possible to add a tab alongside the current "By Organisation" which allows the user to filter and/sort results by the service lifecycle types, i.e. Discovery, Alpha, Beta, Live including those that are inactive (paused), e.g. Clinically Extreme Vulnerable People Service or fully decommissioned.

Review categories

The list of categories has been unchanged for many many years (apart from the addition of covid), and needs a review. It’s mainly based on the GOV.UK taxonomy, but there's a been a few tweaks to that. It could either get updated base on the GOV.UK one, or we could deviate.

Add a CSV version of the data

The data page links to a JSON representation of all the data, but it'd also be useful to link to a CSV version, to make it easier to import into a spreadsheet.

Where there can be multiple values (eg synonyms, organisations, start pages, etc), we’ll have to decide between:

  • creating separate columns (eg org1, org2, org3) and accepting that some of these will often be blank
  • using a separate like | or a ; to separate multiple values within a column

Thoughts welcome!

Provide instructions on how to add and update screenshots

Problem

  1. It’s not clear how screenshots should be added. Digging into the npm scripts you can find a script called screenshots, and running that you get help about the sub commands.

  2. To take a screenshot for 1 service, it looks like you can use npm run screenshots <filename>, but it's not clear what filename should be. Should it be npm run screenshots sorn, or npm run screenshots /app/services/sorn or something else?

  3. Running the command to either update screenshots for all services or 1 service produces an error:

    /Users/paulrobertlloyd/Sites/govuk-services/node_modules/puppeteer-core/lib/cjs/puppeteer/util/assert.js:28
            throw new Error(message);
                  ^
    
    Error: An `executablePath` or `channel` must be specified for `puppeteer-core`
        at assert (/Users/paulrobertlloyd/Sites/govuk-services/node_modules/puppeteer-core/lib/cjs/puppeteer/util/assert.js:28:15)
        at ChromeLauncher.computeLaunchArguments (/Users/paulrobertlloyd/Sites/govuk-services/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ChromeLauncher.js:79:36)
        at async ChromeLauncher.launch (/Users/paulrobertlloyd/Sites/govuk-services/node_modules/puppeteer-core/lib/cjs/puppeteer/node/ProductLauncher.js:83:28)
        at async /Users/paulrobertlloyd/Sites/govuk-services/tasks/screenshot-services.js:84:19
  4. Looks like there are some additional dependencies on the project which are not documented. Digging into tasks/screenshot-services.js, the script is looking for GOOGLE_CHROME_PATH environment variable. Where should this be set? What should it point to?

  5. Are any further settings needed for the screenshot scripts to work?

Solution

  • List project dependencies, and how to install
  • Document screenshot commands in the README, and provide relevant examples
  • Is the above an error, or a problem with not having everything set up correctly?
  • Provide an example of what value to provide for GOOGLE_CHROME_PATH, and how to set it. Perhaps add a project like dotenv and add an example .env.example file.

Search for a service

A simple search box could let you quickly find a service, also using the synonyms, with an autocomplete. Something similar to the one on the Design System website?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.