-
-
Save StephenDRoberts/26584f6655c99fe7fe9d9e0a87abe39a to your computer and use it in GitHub Desktop.
Render table body rows
This file contains 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
renderMonthlyList = (monthlyEntryList) => { | |
let options = []; | |
if (monthlyEntryList && monthlyEntryList.length !== 0) { | |
monthlyEntryList.forEach((entry, index) => { | |
options.push(<tr key={`listRow${index}`}> | |
<td className="col-3" >{entry.date}</td> | |
<td className="col-3" >{entry.type}</td> | |
<td className="col-3" >{entry.retailer}</td> | |
<td className="col-3" >{formatCurrency(entry.currency, entry.value)}</td> | |
</tr> | |
) | |
}) | |
} | |
return options | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment