Anime Page
About 374 wordsAbout 1 min
2025-09-01
Anime Page Modification Tutorial
Mizuka theme provides a built-in anime page, allowing you to easily customize the displayed anime list.
Anime Page Structure
The anime page is located in the src/pages/anime.astro
file. The core of the page is an anime data array:
const animeList = [
{
title: "Lycoris Recoil",
status: "completed",
rating: 9.8,
cover: "assets/anime/lkls.webp",
description: "Girl gunfight, flawed but not hidden",
episodes: "12 episodes",
year: "2022",
genre: ["Action", "Slice of Life"],
studio: "A-1 Pictures",
link: "https://www.bilibili.com/bangumi/media/md28338623",
progress: 12,
totalEpisodes: 12,
startDate: "2022-07",
endDate: "2022-09",
},
// More anime...
];
Modifying the Anime List
To add, delete, or modify anime information, directly edit the animeList
array:
- Add Anime: Copy an existing anime object and modify its properties
- Modify Anime Information: Directly modify the property values of an existing anime object
- Delete Anime: Remove the corresponding anime object from the array
Anime Property Descriptions
Each anime object contains the following properties:
title
: Anime title - The official name or translated name of the animestatus
: Viewing status ("watching" or "completed") - Current viewing progress statusrating
: Rating (0-10) - Personal rating for the animecover
: Cover image path (relative to public directory) - Storage path of the anime cover imagedescription
: Anime description - A brief review or plot summary of the animeepisodes
: Episode information - Description of the total number of episodes of the animeyear
: Broadcast year - The year the anime was first broadcastgenre
: Genre tags - An array of genre tags for the anime, such as ["Action", "Slice of Life"]studio
: Production company - The animation studio responsible for producing the animelink
: Anime link (can point to Bilibili or other platforms) - Link to watch or learn moreprogress
: Viewing progress - Number of episodes currently watchedtotalEpisodes
: Total episodes - The total number of episodes of the animestartDate
: Start broadcast date - The start broadcast time of the anime (format: YYYY-MM)endDate
: End broadcast date - The end broadcast time of the anime (format: YYYY-MM)
Anime Images
To add cover images for anime:
- Place image files in the
public/assets/anime/
directory - Specify the image filename in the
cover
property of the anime object
Ensure image format is WebP for best performance.