Skip to content

Commit

Permalink
fix(home): actions Button 为绝对路径时设置 key (#15)
Browse files Browse the repository at this point in the history
Warning: Each child in a list should have a unique "key" prop.
  • Loading branch information
Aruelius authored Jul 10, 2023
1 parent 2912fd8 commit 0cf1f9c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/layouts/HomePageLayout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ const Homepage: FC = () => {
>
{actions?.map(({ link, text, type }) => {
return /^(\w+:)\/\/|^(mailto|tel):/.test(link) ? (
<Button size="large" type={type} href={link} target="_blank">
<Button size="large" type={type} href={link} target="_blank" key={link}>
{text}
</Button>
) : (
Expand Down

0 comments on commit 0cf1f9c

Please sign in to comment.