Table fix using map.()

  Kiến thức lập trình

I am Need these map to go in each col but they keep Repeating and i have no idea how to fix

How do i get this to stop mappiong insides Other sections of the table

<div className="">
            <table className="table-auto bg-white border-black border-2 mt-5">
                <thead className="">
                    <tr className="flex">
                        <th className="px-4"> Weak to</th>
                        <th className="px-4"> Strong Against</th>
                        <th className="px-4">Half Damg to</th>
                        <th className="px-4"> Half Damg From</th>
                    </tr>
                </thead>
                <tbody>
                
                    {typeinfo.damage_relations.double_damage_from.map((e, index) => (
                        <tr key={index}  className="flex flex-wrap px-2">
                        <td className={`px-2 h-20 cursor-pointer content-${e.name}`}>{e.name}</td>
                    
                        {typeinfo.damage_relations.double_damage_to.map((f, idx) => (
                            <td key={idx} className={`px-2 h-20 cursor-pointer content-${f.name}`}>
                                {f.name}
                            </td>
                            ))}
                            {/* {typeinfo.damage_relations.half_damage_from.map((f, idx) => (
                            <td key={idx} className={`px-2 h-20 cursor-pointer content-${f.name}`}>
                                {f.name}
                            </td>
                            ))}
                            {typeinfo.damage_relations.half_damage_to.map((f, idx) => (
                            <td key={idx} className={`px-2 h-20 cursor-pointer content-${f.name}`}>
                                {f.name}
                            </td>
                            ))} */}

                        </tr>
                  ))}
                </tbody>

            </table>
        </div>

I commented out the last to so i can be last confusing also if i can get an reason why its and how to fix id appreciate it.

LEAVE A COMMENT