Files
morten-olsen.github.io/content/templates/react/theme/provider.tsx
Morten Olsen 9b1a067d56 init
2023-03-27 10:46:18 +02:00

15 lines
374 B
TypeScript

import React, { ReactNode } from 'react';
import { ThemeProvider as StyledThemeProvider } from 'styled-components';
import { Theme } from './theme';
type Props = {
theme: Theme;
children: ReactNode;
};
const ThemeProvider: React.FC<Props> = ({ theme, children }) => (
<StyledThemeProvider theme={theme}>{children}</StyledThemeProvider>
);
export { ThemeProvider };