style: Try biome

This commit is contained in:
BuyMyMojo 2024-12-19 11:53:42 +11:00
parent 54b4349667
commit 7ed39cd0df
Signed by: aria
GPG key ID: 19AB7AA462B8AB3B
11 changed files with 180 additions and 152 deletions

View file

@ -7,25 +7,25 @@ import "../styles/aria.css";
const pageTitle = "About Aria";
const identity = {
firstName: "Aria",
country: "Australia",
occupation: "Phone & Computer Repair Tech",
hobbies: ["gaming", "software/game development", "3D printing"],
firstName: "Aria",
country: "Australia",
occupation: "Phone & Computer Repair Tech",
hobbies: ["gaming", "software/game development", "3D printing"],
};
const skills = ["Rust", "GDScript", "FFMPEG"];
const currentSystem = {
name: "I/O",
operatingSystem: "EndeavourOS",
host: "X570 Phantom Gaming 4",
shell: "zsh",
mainDisplay: "Gigabyte M27U",
mainDisplayRtings: "https://www.rtings.com/monitor/reviews/gigabyte/m27u",
cpu: "AMD Ryzen 9 5900X",
gpu: "AMD Radeon RX 7800 XT",
ram: "48GB",
localIP: "192.168.20.2",
name: "I/O",
operatingSystem: "EndeavourOS",
host: "X570 Phantom Gaming 4",
shell: "zsh",
mainDisplay: "Gigabyte M27U",
mainDisplayRtings: "https://www.rtings.com/monitor/reviews/gigabyte/m27u",
cpu: "AMD Ryzen 9 5900X",
gpu: "AMD Radeon RX 7800 XT",
ram: "48GB",
localIP: "192.168.20.2",
};
const skillColor = "#F5A8B7";

View file

@ -1,12 +1,13 @@
---
import { getCollection, render } from 'astro:content';
import MarkdownPostLayout from '../../layouts/MarkdownPostLayout.astro';
import { getCollection, render } from "astro:content";
import MarkdownPostLayout from "../../layouts/MarkdownPostLayout.astro";
export async function getStaticPaths() {
const posts = await getCollection('blog');
return posts.map(post => ({
params: { slug: post.id }, props: { post },
}));
const posts = await getCollection("blog");
return posts.map((post) => ({
params: { slug: post.id },
props: { post },
}));
}
const { post } = Astro.props;

View file

@ -1,18 +1,18 @@
import rss from '@astrojs/rss';
import rss from "@astrojs/rss";
import { getCollection } from "astro:content";
export async function GET(context) {
const posts = await getCollection("blog");
return rss({
title: "Aria | Blog",
description: "Just me being a silly little thing",
site: context.site,
items: posts.map((post) => ({
title: post.data.title,
pubDate: post.data.pubDate,
description: post.data.description,
link: `/posts/${post.id}/`,
})),
customData: `<language>en-us</language>`,
});
const posts = await getCollection("blog");
return rss({
title: "Aria | Blog",
description: "Just me being a silly little thing",
site: context.site,
items: posts.map((post) => ({
title: post.data.title,
pubDate: post.data.pubDate,
description: post.data.description,
link: `/posts/${post.id}/`,
})),
customData: `<language>en-us</language>`,
});
}

View file

@ -6,21 +6,21 @@ import BlogEntry from "../../components/BlogEntry.astro";
import Partition from "../../components/Partition.astro";
export async function getStaticPaths() {
const allPosts = await getCollection("blog");
const allPosts = await getCollection("blog");
const uniqueTags = [
...new Set(allPosts.map((post: any) => post.data.tags).flat()),
];
const uniqueTags = [
...new Set(allPosts.map((post: any) => post.data.tags).flat()),
];
return uniqueTags.map((tag) => {
const filteredPosts = allPosts.filter((post: any) =>
post.data.tags.includes(tag)
);
return {
params: { tag },
props: { posts: filteredPosts },
};
});
return uniqueTags.map((tag) => {
const filteredPosts = allPosts.filter((post: any) =>
post.data.tags.includes(tag),
);
return {
params: { tag },
props: { posts: filteredPosts },
};
});
}
const { tag } = Astro.params;

View file

@ -4,9 +4,7 @@ import { getCollection } from "astro:content";
import BaseLayout from "../../layouts/BaseLayout.astro";
import Partition from "../../components/Partition.astro";
const allPosts = await getCollection("blog");
const tags = [
...new Set(allPosts.map((post: any) => post.data.tags).flat()),
];
const tags = [...new Set(allPosts.map((post: any) => post.data.tags).flat())];
const pageTitle = "Tag Index";
---