Last active
July 10, 2021 03:54
-
-
Save jasonleehodges/1e6b3e145de7793ed2393568e70b04c6 to your computer and use it in GitHub Desktop.
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 from 'react'; | |
| export const Grid = (props) => { | |
| const renderRow = (rowData) => ( | |
| <div className="row"> | |
| <div className="col"> | |
| {rowData.title} | |
| </div> | |
| <div className="col"> | |
| {rowData.description} | |
| </div> | |
| <div className="col"> | |
| {rowData.date} | |
| </div> | |
| </div> | |
| ) | |
| return ( | |
| <div className="grid__container"> | |
| {props.data.map((datum) => renderRow(datum))} | |
| </div> | |
| ) | |
| }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment