--- import Layout from "../layouts/Layout.astro"; import Navbar from "../components/widgets/Navbar.astro"; import Container from "../components/atoms/Container.astro"; interface Project { name: string; link: string; desc: string; stats?: { forks: number; stars: number; }; } const projects: Project[] = [ { name: "HyLib", link: "https://github.com/xHyroM/HyLib", desc: "Source code for HyLib, a paper plugin and powerful library.", }, { name: "HyChat", link: "https://github.com/xHyroM/HyChat", desc: "Source code for HyChat, a paper plugin.", }, { name: "HyX", link: "https://github.com/xHyroM/HyX", desc: "Lorem ipsum dolor sit amet consectetur adipisicing elit. Cumque, quaerat.", }, { name: "Mashe", link: "https://github.com/xHyroM/mashe", desc: "Simple, fast, and easy to use Event Handling for Java.", }, { name: "Mumblum", link: "https://github.com/xHyroM/mumblum", desc: "Mumblum is a simple, modern discord bot in JDA.", }, { name: "setup-bun", link: "https://github.com/xHyroM/setup-bun", desc: "Set up your GitHub Actions workflow with a specific version of Bun.", }, { name: "Roles Bot", link: "https://github.com/xHyroM/roles-bot", desc: 'Discord bot for "button" roles, using Cloudflare Workers.', }, { name: "Bun Discord Bot", link: "https://github.com/xHyroM/bun-discord-bot", desc: "Official serverless discord bot for bun discord server.", }, { name: "hykord", link: "https://github.com/xHyroM/hykord", desc: "My @discord client modification.", }, { name: "frog", link: "https://github.com/xHyroM/frog", desc: "Frog is an extremely simple language based on the monkey language.", }, { name: "lsx", link: "https://github.com/xHyroM/lsx", desc: "Lsx is a simple, fast, and easy to use ls implementation in Rust.", }, { name: "Slovensko v Grafoch", link: "https://github.com/xHyroM/slovensko-v-grafoch", desc: "Slovensko v Grafoch is a website that shows data about Slovakia in graphs.", }, { name: "Peddler's Pocket", link: "https://github.com/xHyroM/peddlerspocket", desc: "CLOSED SOURCE NOW | /sell command that allows you to put things into GUI and then sell them by closing", }, { name: "Peak Pursuit", link: "https://github.com/xHyroM/peakpursuit", desc: "CLOSED SOURCE NOW | PeakPursuit is a plugin for King of the Hill events that adds a competitive edge to your server gameplay. Conquer the hill and claim the crown!", }, { name: "Spawner Genz", link: "https://github.com/xHyroM/spawnergenz", desc: "CLOSED SOURCE NOW | Spawner Genz is a plugin that modifies the functionality of spawners so that they don't spawn entities, but instead store drops in a virtual storag in which you can then sell or move everything to your inventory.", }, ]; for (const project of projects) { const repository = await ( await fetch(`https://api.github.com/repos/${project.link.slice(19)}`, { headers: { Authorization: `Bearer ${import.meta.env.GITHUB_ACCESS_TOKEN}`, }, }) ).json(); project.stats = { forks: repository.forks, stars: repository.stargazers_count, }; } projects.sort((a, b) => a.name.localeCompare(b.name)); --- ({ "@type": "ListItem", position: i + 1, name: project.name, url: project.link, })), }} >

Projects

{ projects.map((project) => (

{project.name}

{project.stats!.stars}

{" "}

{project.stats!.forks}

{project.desc}

)) }