diff options
| author | Factiven <[email protected]> | 2023-06-29 04:55:17 +0000 |
|---|---|---|
| committer | Factiven <[email protected]> | 2023-06-29 04:55:17 +0000 |
| commit | 1d53be6945a5b5bab699fa956cd213c44252a3b0 (patch) | |
| tree | ad80d9ab616d40f4fc703672522d21ef29acd84a | |
| parent | fixed empty section on homepage when using AniList (diff) | |
| download | moopa-1d53be6945a5b5bab699fa956cd213c44252a3b0.tar.xz moopa-1d53be6945a5b5bab699fa956cd213c44252a3b0.zip | |
Update index.js
| -rw-r--r-- | pages/index.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pages/index.js b/pages/index.js index 755aa2d..05a09d6 100644 --- a/pages/index.js +++ b/pages/index.js @@ -455,7 +455,7 @@ export default function Home({ detail, populars, sessions }) { animate={{ opacity: 1 }} transition={{ duration: 0.5, staggerChildren: 0.2 }} // Add staggerChildren prop > - {sessions && onGoing.length > 0 && ( + {sessions && onGoing?.length > 0 && ( <motion.div // Add motion.div to each child component key="onGoing" initial={{ y: 20, opacity: 0 }} @@ -472,7 +472,7 @@ export default function Home({ detail, populars, sessions }) { </motion.div> )} - {sessions && list.length > 0 && ( + {sessions && list?.length > 0 && ( <motion.div // Add motion.div to each child component key="listAnime" initial={{ y: 20, opacity: 0 }} @@ -489,7 +489,7 @@ export default function Home({ detail, populars, sessions }) { )} {/* SECTION 2 */} - {sessions && planned.length > 0 && ( + {sessions && planned?.length > 0 && ( <motion.div // Add motion.div to each child component key="plannedAnime" initial={{ y: 20, opacity: 0 }} |