import "./trending.css";
import Image from "next/image";
import Link from "next/link";
export default async function Trending() {
const data = await test();
return (
Trending
{data &&
data.results.map((item, index) => (
{item.title}
))}
);
}
async function test() {
const res = await fetch(
"https://consumet-api-di2e.onrender.com/anime/gogoanime/top-airing",
{ cache: "force-cache" }
);
const data = res.json();
return data;
}