About this project
The rig provides all you need to build interactive prototypes that look like pages on GOV.UK.
Prototypes can be used to show ideas to people you work with, and during user research.
Differences from the Prototype Kit
The rig is a re-imagined version of the GOV.UK Prototype Kit aimed at developers familiar with the Nunjucks template language.
The Prototype Rig works in exactly the same way as the kit. It stores data in the session, uses GOV.UK Frontend components, and supports hosting prototypes on services like Heroku.
Unlike the Prototype Kit, the rig doesn’t provide support for GOV.UK elements (superseded by the GOV.UK Design System in 2018) or the kit’s extensions feature.
Unbranded templates, jQuery and stylesheets for Internet Explorer 8 are also not included, but can be added if required.
Features
- Default 404 page
- Error page that shows the cause of the error
- Feature flags
- Session data output to the JavaScript console
- Ability to use
async
functions for session data - Support for form validation
- Form component helper
- Nunjucks template filters
- Common components not currently in the GOV.UK Design System
- A wizard helper to help create user journeys with branching logic
- Full documentation
The underlying tooling has also been updated:
- Rewritten using ES modules
- Tasks run using npm scripts
- CSS linting using Stylelint
- Sass compiled using the Dart library
- Assets compiled and bundled using rollup.js
All code is documented using JSDoc.
Privacy
You must protect user privacy at all times, even when using prototypes. Prototypes made with the rig look like GOV.UK, but do not have the same security provisions. Always make sure you are handling user data appropriately.
The rig is not a production framework
Things made with the rig may look like GOV.UK, but do not have production code and likely aren’t fully accessible. Don’t use the rig as a base for a production service.