Last active
November 19, 2019 10:46
-
-
Save garima33/27d95f91c6844f424f0d2d1781189a93 to your computer and use it in GitHub Desktop.
grid-demo-emotion
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from "react"; | |
| import { Flex, DataWrapper } from "./styled-components/index"; | |
| import { data } from "./utils/data"; | |
| import { Card } from "./components/Card"; | |
| import "./App.css"; | |
| class App extends Component { | |
| render() { | |
| let items = data.map((item, index) => { | |
| return ( | |
| <DataWrapper key={index}> | |
| <Card cardData={item} /> | |
| </DataWrapper> | |
| ); | |
| }); | |
| // color can be customized by passing it as a prop. | |
| return <Flex color="black">{items}</Flex>; | |
| } | |
| } | |
| export default App; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment