Components
Explore Matchbox's React component library
Getting Started with Matchbox
First install the component library with NPM. Our components are styled with javascript via styled-components, install this too.
npm install @sparkpost/matchbox @sparkpost/matchbox-icons styled-components --save
Optionally, if you plan on styling with Matchbox, install our design token library.
npm install @sparkpost/design-tokens --save
Wrap your React app with our ThemeProvider
component:
import { ThemeProvider } from '@sparkpost/matchbox';function App(props) {return <ThemeProvider>{props.children}</ThemeProvider>;}
That's it!
For information on how to use and style Matchbox components:
- Read our design token guide
- Read our system prop guide
- Read docs for a component. Button is a good one!