tangled
alpha
login
or
join now
olaren.dev
/
pdsls
forked from
pds.ls/pdsls
0
fork
atom
atmosphere explorer
0
fork
atom
overview
issues
pulls
pipelines
feat: better front page random
olaren.dev
1 month ago
0d11df25
d4652f59
+8
-1
1 changed file
expand all
collapse all
unified
split
src
views
home.tsx
+8
-1
src/views/home.tsx
···
64
64
{ did: "did:plc:vafqb3yhndyawabm2t2zhw5z", handle: "neko.moe.observer" },
65
65
];
66
66
67
67
-
const profiles = [...allExampleProfiles].sort(() => Math.random() - 0.5).slice(0, 3);
67
67
+
for (let i = allExampleProfiles.length - 1; i > 0; i--) {
68
68
+
const j = Math.floor(Math.random() * (i + 1));
69
69
+
[allExampleProfiles[i], allExampleProfiles[j]] = [
70
70
+
allExampleProfiles[j],
71
71
+
allExampleProfiles[i],
72
72
+
];
73
73
+
}
74
74
+
const profiles = allExampleProfiles.slice(0, 3);
68
75
69
76
return (
70
77
<div class="flex w-full flex-col gap-5 px-2 wrap-break-word">