spotube/website/src/routes/+page.ts
Kingkor Roy Tirtho cd669e22c1
website: new sveltekit based website (#1239)
* feat: initialize website project

* feat: add initial homepage with download links

* feat: initial download page

* fix: linux icon color

* feat: add mobile nav and github star button

* feat: add older and nightly downloads page

* feat: add supporters and footer

* feat: add author details in about page

* feat: add darkmode toggle for website

* feat: add playstore and flathub download buttons and contribution button

* feat: add blogs support

* feat: remove netlify deploy config and add cloudflare config and favicons + manifest

* chore: add robots.txt

* feat: add spotube logo in navbar and fix build errors

* chore: add gap
2024-02-17 13:48:27 +06:00

35 lines
728 B
TypeScript

interface Member {
MemberId: number;
createdAt: string;
type: string;
role: string;
isActive: boolean;
totalAmountDonated: number;
currency?: string;
lastTransactionAt: string;
lastTransactionAmount: number;
profile: string;
name: string;
company?: string;
description?: string;
image?: string;
email?: string;
twitter?: string;
github?: string;
website?: string;
tier?: string;
}
export const load = async () => {
const res = await fetch('https://opencollective.com/spotube/members/all.json');
const members = (await res.json()) as Member[];
return {
props: {
members: members
.filter((m) => m.totalAmountDonated > 0)
.sort((a, b) => b.totalAmountDonated - a.totalAmountDonated)
}
};
};