aboutsummaryrefslogtreecommitdiff
path: root/src/app/anime/search/components/fetchInfo.js
blob: 2f813455dda511f19f4b5c8af70ccc19ce9446ea (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
"use server";

export default async function Results(id) {
	return await testFunction(id);
}

async function testFunction(title) {
	const res = await fetch(
		"https://consumet-jade.vercel.app/anime/gogoanime/" + title,
		{ next: { revalidate: 21600 } }
	);
	const data = await res.json();
	return data;
}