ThemeProvider

A wrapper component for Matchbox's theming. Injects Matchbox's styling into all Matchbox components beneath it in the component tree, via the context API.


import { ThemeProvider } from '@sparkpost/matchbox';
function App() {
return <ThemeProvider>Your App Here</ThemeProvider>;
}

children
node
Required
Child contents will have access to Matchbox's styling. All Matchbox components need to be a child of ThemeProvider.
skipGlobalStyles
bool
Skips injecting global styles. Useful for test runners.
target
DOM element
Provides an alternate DOM node to inject styled-components stylesheets into. See styled-components.com/docs/api#stylesheetmanager.