Skip to content

Instantly share code, notes, and snippets.

@3ndrius
Created January 1, 2019 22:12
Show Gist options
  • Save 3ndrius/3739b1fc9119df7a64385a1eb44d723e to your computer and use it in GitHub Desktop.
Save 3ndrius/3739b1fc9119df7a64385a1eb44d723e to your computer and use it in GitHub Desktop.
import React from 'react'
import {createGlobalStyle, ThemeProvider} from 'styled-components';
import { theme } from './../utils/theme';
const GlobalStyle = createGlobalStyle`
body {
padding: 0;
box-sizing:border-box;
margin 0;
background:${({theme}) => theme.colors.light}
font-family: Montserrat,'Segoe UI', sans-serif ;
color:${({theme}) => theme.colors.dark}
}
`;
export default function Layout({children}) {
return (
<ThemeProvider theme={theme}>
<>
<GlobalStyle />
{children}
</>
</ThemeProvider>
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment