Skip to content

Official government website An official website of the Federal Government of Nigeria

How you know
Federal Ministry of Communications, Innovation & Digital Economy Nigerian Design Standards

React kit

NDS components for React use the same markup as the HTML and WordPress versions. The kit is free and you don’t need a key.

Version 1.0.0 React 18 or later TypeScript types

Install

Three steps to your first component. You’ll need Node.js and a React app.

  1. 1. Install the packages

    @nigerian-design-standards/react has the components. @nigerian-design-standards/styles has the styles they share with the HTML and WordPress versions.

              $ npm install @nigerian-design-standards/react @nigerian-design-standards/styles
            
  2. 2. Add the styles

    Import them once, in your app’s entry file, before your own styles.

              import "@nigerian-design-standards/styles";
            
  3. 3. Use a component

    Props use the same names as on each component’s page.

              import { Button } from "@nigerian-design-standards/react";
    
    <Button variant="primary">Continue</Button>
            

What’s included

One package for every approved component, kept in step with the HTML and WordPress versions.

  1. 01 Components Every approved component, from button to data table
  2. 02 Styles Tokens and CSS from @nigerian-design-standards/styles, shared with the HTML version
  3. 03 Types TypeScript types for every component and prop
  4. 04 Accessibility Labels, focus and ARIA built into each component

Requirements

React kit requirements
React 18 or later Works with React 18 and 19, including Next.js and Vite.
Browsers Last 2 versions The same browsers as the HTML version.
TypeScript Optional Types are included. You don’t need TypeScript to use the kit.

Using it well

The kit gets each component right. How you put them together is up to you.

  • Follow the guidance

    Each component’s page says when to use it and what to write.

  • Don’t restyle components

    If you need a change, ask the NDS team so every service gets it.

  • Test your pages

    The kit makes each component accessible. Test how you combine them.

Release notes

  • 1.0.0 First stable release, matching NDS 1.0.
  • 0.9.0 Beta: form components and error summary.
  • 0.8.0 Alpha: foundations and button.