홈 페이지 구현

This commit is contained in:
static
2025-12-26 22:47:31 +09:00
parent ed21a9cd31
commit 6d02178c69
8 changed files with 50 additions and 7 deletions

View File

@@ -0,0 +1,10 @@
import { getAllFileInfos } from "$lib/indexedDB";
export const requestFreshFilesRetrieval = async (limit = 8) => {
const files = await getAllFileInfos();
files.sort(
(a, b) =>
(b.createdAt ?? b.lastModifiedAt).getTime() - (a.createdAt ?? a.lastModifiedAt).getTime(),
);
return files.slice(0, limit);
};