doc: add data to Table component
This commit is contained in:
1 parent
954ae57aa8
commit
a48b4d3027
1 file changed
+13
-2
+13
-2
@@ -1,8 +1,19 @@
|
||||
import React from "react";
|
||||
import "./Table.css";
|
||||
|
||||
function Table() {
|
||||
return <section></section>;
|
||||
function Table({ countries }) {
|
||||
return (
|
||||
<section className="table">
|
||||
{countries.map(({ country, cases }) => (
|
||||
<tr>
|
||||
<td>{country}</td>
|
||||
<td>
|
||||
<strong>{cases}</strong>
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
||||
export default Table;
|
||||
Reference in new issue
Block a user