Merge pull request #424 from w3irdrobot/key-on-tabs

Added key attr to Tabs to remove React warning
This commit is contained in:
2023-03-10 20:52:01 +00:00
committed by GitHub

View File

@ -32,7 +32,7 @@ const Tabs = ({ tabs, tab, setTab }: TabsProps) => {
return (
<div className="tabs" ref={horizontalScroll}>
{tabs.map(t => (
<TabElement tab={tab} setTab={setTab} t={t} />
<TabElement key={t.value} tab={tab} setTab={setTab} t={t} />
))}
</div>
);