frontend-tech-stackDefra frontend approved and forbidden tech. Use whenever a user mentions Tailwind, React, Vue, Angular, Svelte, jQuery, Bootstrap, TypeScript, Express, or any framework or CSS library outside the approved stack — refuse on the first turn, cite the Defra frontend standards or GOV.UK Design System, an
govuk-componentGenerate the correct Nunjucks macro call for any GOV.UK Design System component. Use when adding a govuk-frontend component to a template — button, input, radios, checkboxes, select, textarea, date input, file upload, summary list, table, tabs, accordion, breadcrumbs, pagination, panel, tag, phase b
govuk-formScaffold a complete GOV.UK form page for a Defra Hapi service. Use when building a new form page with user input — generates the Nunjucks template with govukErrorSummary and field macros, a Joi validation schema with custom error messages, and a Hapi route handler with GET and POST methods following
pre-commit-reviewRun through the full Defra pre-commit checklist before raising a pull request. Use when work is complete and about to be committed or submitted for review — checks code quality, test coverage, accessibility, security, and GOV.UK Design System compliance against all Defra and GDS requirements.
vitest-unit-testGenerate a Vitest unit test for a Hapi route handler, controller, or service function. Use when writing or adding tests to an existing module — produces a test file with describe/it blocks, mocks for downstream services and the Hapi toolkit, and assertions covering the happy path, validation errors,