I try to create a table with two arrays in a state(week_today, week_count) and a repeating sentence when rendering. I don't know how to use map() function . Please advise.
my code
render() {
const {week_today, week_count} = this.state; // this.state in my array put
return (
<div>
<table class="table">
<thead class="thead-dark">
<tr>
<th scope="col">today</th>
<th scope="col">count</th>
</tr>
</thead>
<tbody>
//<== here my array table
</tbody>
</table>
</div>
)
}
use my arrays
week_today = [ 01,02,03,04,05]
week_count = [ 1,2,3,4,5]