We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cb25913 commit 3d91164Copy full SHA for 3d91164
1 file changed
index.html
@@ -16,7 +16,11 @@
16
return res.json();
17
})
18
.then(data => {
19
- data.reverse()
+ data.sort((a, b) => {
20
+ b1 = !a.includes("beta"); b2 = !b.includes("beta")
21
+ if (b1 ^ b2) return b2 - b1 // boolean subtraction
22
+ return b.split("_").at(-1).substring(1) - a.split("_").at(-1).substring(1) // string subtraction
23
+ })
24
quicklink = document.getElementById("quicklink")
25
newest = data[0]
26
quicklink.href = "https://rawcdn.githack.com/Minecraft-Java-Edition-Speedrunning/rules/main/pub/pdf/" + newest.name
@@ -45,3 +49,4 @@ <h3 id="rules">Past releases:</h3>
45
49
46
50
</html>
47
51
52
+
0 commit comments