This repository contains the code for NHS.UK React components - a port of the NHS.UK Frontend components.
View documentation and examples
You can install this package using either yarn or npm.
npm install --save nhsuk-react-components
# Or
yarn add nhsuk-react-componentsimport { PureComponent } from 'react';
// You can import components from the global module
import { Button } from 'nhsuk-react-components';
// Or you can import components directly
import { Button } from 'nhsuk-react-components/dist/esm/components/button';
class GetStartedButton extends PureComponent {
render() {
return <Button>Click Me!</Button>;
}
}- Upgrading to 1.0
- Upgrading to 2.0
- Upgrading to 3.0
- Upgrading to 4.0
- Upgrading to 5.0
- Upgrading to 6.0
We’re currently looking for new maintainers If you have knowledge of React and would be willing to help maintain this library, you can email me (Thomas Judd-Cooper).
- Thomas Judd-Cooper (GitHub)
- Sam Brown (GitHub)
- Luke Pearson (GitHub)
- Kevin Kuszyk (GitHub)
- Kai Spencer (GitHub)
- Ed Horsford (GitHub)
Releases run in CI using github actions.
To prepare a release create a new release TAG in github with your release version.
NPM_TOKENshould be stored in the repositories secrets in GitHub
- Create a new release with a tag like
major.minor.patchagainst main. - If the change is a
betathen selectpre-releaseas true, this will make thetagpoint atbeta. Otherwise the tag will belatest.
Thanks to Chromatic for providing the visual testing platform that helps us review UI changes and catch visual regressions.