[fix] key not exist error

This commit is contained in:
expoli
2023-10-29 19:42:38 +08:00
parent fd29df3b26
commit 61f014e60f
3 changed files with 18 additions and 0 deletions

View File

@@ -16,6 +16,12 @@ const MenuGroupCard = (props) => {
{ name: locale.COMMON.TAGS, to: '/tag', slot: tagSlot, show: CONFIG.MENU_TAG }
]
for (let i = 0; i < links.length; i++) {
if (links[i].id !== i) {
links[i].id = i
}
}
return (
<nav id='nav' className='leading-8 flex justify-center dark:text-gray-200 w-full'>
{links.map(link => {