🏗 Sets up styled-components

This commit is contained in:
Alicia Sykes
2022-06-11 22:36:48 +01:00
parent 16f2df8632
commit 2f0bc8199b
4 changed files with 131 additions and 48 deletions

View File

@@ -1,38 +0,0 @@
.App {
text-align: center;
}
.App-logo {
height: 40vmin;
pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
.App-logo {
animation: App-logo-spin infinite 20s linear;
}
}
.App-header {
background-color: #282c34;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-size: calc(10px + 2vmin);
color: white;
}
.App-link {
color: #61dafb;
}
@keyframes App-logo-spin {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}

View File

@@ -1,13 +1,22 @@
import React from 'react';
import Styled from 'styled-components';
import Demo from 'components/Demo';
import 'App.css';
const Container = Styled.div`
background: #bfc;
width: fit-content;
margin: 1rem auto;
padding: 0.5rem 1rem;
border-radius: 6px;
`;
function App() {
return (
<div className="App">
<Container className="App">
<h1>Hello 👋</h1>
<Demo message="React is Dumb," />
</div>
</Container>
);
}