mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 10:03:31 +01:00
chore(website): switch to revalidate on fetch level
This commit is contained in:
@@ -3,7 +3,7 @@ import { NextResponse, type NextRequest } from 'next/server';
|
||||
import { PACKAGES } from './util/constants';
|
||||
|
||||
async function fetchLatestVersion(packageName: string) {
|
||||
const res = await fetch(`https://docs.discordjs.dev/api/info?package=${packageName}`);
|
||||
const res = await fetch(`https://docs.discordjs.dev/api/info?package=${packageName}`, { cache: 'no-store' });
|
||||
const data: string[] = await res.json();
|
||||
|
||||
return data.at(-2);
|
||||
|
||||
Reference in New Issue
Block a user