biome setup

This commit is contained in:
Oliver Bryan
2026-01-14 23:17:45 +00:00
parent 9b699d48be
commit 10ce0f65c9
23 changed files with 233 additions and 226 deletions

View File

@@ -1,4 +1,4 @@
{
"recommendations": ["astro-build.astro-vscode"],
"unwantedRecommendations": []
"recommendations": ["astro-build.astro-vscode"],
"unwantedRecommendations": []
}

18
.vscode/launch.json vendored
View File

@@ -1,11 +1,11 @@
{
"version": "0.2.0",
"configurations": [
{
"command": "./node_modules/.bin/astro dev",
"name": "Development server",
"request": "launch",
"type": "node-terminal"
}
]
"version": "0.2.0",
"configurations": [
{
"command": "./node_modules/.bin/astro dev",
"name": "Development server",
"request": "launch",
"type": "node-terminal"
}
]
}

View File

@@ -1,20 +1,19 @@
// @ts-check
import { defineConfig } from 'astro/config';
import vercel from '@astrojs/vercel';
import react from "@astrojs/react";
import react from '@astrojs/react';
import vercel from "@astrojs/vercel";
import tailwindcss from "@tailwindcss/vite";
import { defineConfig } from "astro/config";
import tailwindcss from '@tailwindcss/vite';
import icon from 'astro-icon';
import icon from "astro-icon";
// https://astro.build/config
export default defineConfig({
adapter: vercel(),
integrations: [react(), icon()],
adapter: vercel(),
integrations: [react(), icon()],
vite: {
plugins: [tailwindcss()]
}
vite: {
plugins: [tailwindcss()],
},
});

54
biome.json Normal file
View File

@@ -0,0 +1,54 @@
{
"$schema": "https://biomejs.dev/schemas/2.3.11/schema.json",
"vcs": {
"enabled": true,
"clientKind": "git",
"useIgnoreFile": true
},
"files": {
"includes": ["**", "!!**/dist"]
},
"formatter": {
"enabled": true,
"formatWithErrors": false,
"indentStyle": "space",
"indentWidth": 4,
"lineWidth": 110
},
"linter": {
"enabled": true,
"rules": {
"recommended": true
}
},
"overrides": [
{
"includes": ["**/*.svelte", "**/*.astro", "**/*.vue"],
"linter": {
"rules": {
"style": {
"useConst": "off",
"useImportType": "off"
},
"correctness": {
"noUnusedVariables": "off",
"noUnusedImports": "off"
}
}
}
}
],
"javascript": {
"formatter": {
"quoteStyle": "double"
}
},
"assist": {
"enabled": true,
"actions": {
"source": {
"organizeImports": "on"
}
}
}
}

View File

@@ -1,27 +1,27 @@
{
"name": "oliver-bryan-dev",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev",
"build": "astro build",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.9.4",
"@astrojs/react": "^4.3.0",
"@astrojs/vercel": "^8.2.7",
"@iconify-json/mdi": "^1.2.3",
"@iconify-json/simple-icons": "^1.2.66",
"@tailwindcss/vite": "^4.1.13",
"@types/react": "^19.1.12",
"@types/react-dom": "^19.1.9",
"astro": "^5.13.5",
"astro-icon": "^1.1.5",
"react": "^19.1.1",
"react-dom": "^19.1.1",
"tailwindcss": "^4.1.13",
"typescript": "^5.9.2"
}
"name": "oliver-bryan-dev",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev",
"build": "astro build",
"preview": "astro preview",
"astro": "astro"
},
"dependencies": {
"@astrojs/check": "^0.9.4",
"@astrojs/react": "^4.3.0",
"@astrojs/vercel": "^8.2.7",
"@iconify-json/mdi": "^1.2.3",
"@iconify-json/simple-icons": "^1.2.66",
"@tailwindcss/vite": "^4.1.13",
"@types/react": "^19.1.12",
"@types/react-dom": "^19.1.9",
"astro": "^5.13.5",
"astro-icon": "^1.1.5",
"react": "^19.1.1",
"react-dom": "^19.1.1",
"tailwindcss": "^4.1.13",
"typescript": "^5.9.2"
}
}

View File

@@ -1 +1,20 @@
{"weight":200,"italic":false,"alternates":{"cv01":false,"cv02":false,"cv03":false,"cv04":false,"cv05":true,"cv06":false,"cv07":false,"cv08":false,"cv09":false,"cv10":false,"cv11":false},"features":{"ss01":false,"ss02":false,"ss03":true,"ss04":true,"ss05":true},"letterSpacing":0,"lineHeight":1}
{
"weight": 200,
"italic": false,
"alternates": {
"cv01": false,
"cv02": false,
"cv03": false,
"cv04": false,
"cv05": true,
"cv06": false,
"cv07": false,
"cv08": false,
"cv09": false,
"cv10": false,
"cv11": false
},
"features": { "ss01": false, "ss02": false, "ss03": true, "ss04": true, "ss05": true },
"letterSpacing": 0,
"lineHeight": 1
}

View File

@@ -3,9 +3,9 @@ import { Icon } from "astro-icon/components";
import { AI_SUMMARY_PROMPT } from "../lib/constants";
interface Props {
url: string; // anything that precedes the prompt: e.g. "https://ai.example.com/?prompt="
title: string;
icon: string;
url: string; // anything that precedes the prompt: e.g. "https://ai.example.com/?prompt="
title: string;
icon: string;
}
const { url, title, icon } = Astro.props;

View File

@@ -2,7 +2,7 @@
import { Icon } from "astro-icon/components";
import type { AstroModule, ProjectMetadata } from "../pages/index.astro";
interface Props {}
type Props = {};
const {} = Astro.props;
@@ -17,17 +17,17 @@ options.push({
});
// add all individual projects to options
Object.values(
import.meta.glob<AstroModule>("../pages/projects/*.astro", { eager: true })
).forEach((module) => {
const metadata = module.metadata as ProjectMetadata;
if (metadata && !metadata.hidden) {
options.push({
name: `${metadata.title}`,
location: `/projects/${metadata.slug}`,
});
}
});
Object.values(import.meta.glob<AstroModule>("../pages/projects/*.astro", { eager: true })).forEach(
(module) => {
const metadata = module.metadata as ProjectMetadata;
if (metadata && !metadata.hidden) {
options.push({
name: `${metadata.title}`,
location: `/projects/${metadata.slug}`,
});
}
},
);
---
<script>

View File

@@ -2,6 +2,7 @@
import "../styles/global.css";
import CommandPalette from "../components/CommandPalette.astro";
import Header from "../components/Header.astro";
const { currentPage } = Astro.props;
---

View File

@@ -2,8 +2,7 @@
import Layout from "../layouts/Layout.astro";
const weights = [
200, 225, 250, 275, 300, 325, 350, 375, 400, 425, 450, 475, 500, 525, 550,
575, 600, 625, 650, 675, 700,
200, 225, 250, 275, 300, 325, 350, 375, 400, 425, 450, 475, 500, 525, 550, 575, 600, 625, 650, 675, 700,
];
const sampleText = "The quick brown fox jumps over the lazy dog 0123456789.";

View File

@@ -7,76 +7,76 @@ import Layout from "../layouts/Layout.astro";
import { AI_SUMMARY_PROMPT } from "../lib/constants";
export interface ProjectMetadata {
title: string;
description: string;
date: string;
slug: string;
hidden: boolean;
image?: string;
tags?: string[];
type: string;
title: string;
description: string;
date: string;
slug: string;
hidden: boolean;
image?: string;
tags?: string[];
type: string;
}
export interface AstroModule {
metadata?: ProjectMetadata;
metadata?: ProjectMetadata;
}
function parseDate(dateStr: string): Date {
// formats like "February 2024", "January - June 2024", "Q1 2023", etc
const lower = dateStr.toLowerCase();
// formats like "February 2024", "January - June 2024", "Q1 2023", etc
const lower = dateStr.toLowerCase();
if (lower.includes("q1")) return new Date("2023-01-01");
if (lower.includes("q2")) return new Date("2023-04-01");
if (lower.includes("q3")) return new Date("2023-07-01");
if (lower.includes("q4")) return new Date("2023-10-01");
if (lower.includes("q1")) return new Date("2023-01-01");
if (lower.includes("q2")) return new Date("2023-04-01");
if (lower.includes("q3")) return new Date("2023-07-01");
if (lower.includes("q4")) return new Date("2023-10-01");
const months: Record<string, number> = {
january: 0,
february: 1,
march: 2,
april: 3,
may: 4,
june: 5,
july: 6,
august: 7,
september: 8,
october: 9,
november: 10,
december: 11,
};
const months: Record<string, number> = {
january: 0,
february: 1,
march: 2,
april: 3,
may: 4,
june: 5,
july: 6,
august: 7,
september: 8,
october: 9,
november: 10,
december: 11,
};
// month and year
for (const [monthName, monthIndex] of Object.entries(months)) {
if (lower.includes(monthName)) {
const yearMatch = dateStr.match(/\b(20\d{2})\b/);
if (yearMatch) {
return new Date(parseInt(yearMatch[1]), monthIndex, 1);
}
// month and year
for (const [monthName, monthIndex] of Object.entries(months)) {
if (lower.includes(monthName)) {
const yearMatch = dateStr.match(/\b(20\d{2})\b/);
if (yearMatch) {
return new Date(parseInt(yearMatch[1]), monthIndex, 1);
}
}
}
}
// fallback: try to extract any year
const yearMatch = dateStr.match(/\b(20\d{2})\b/);
if (yearMatch) {
return new Date(parseInt(yearMatch[1]), 0, 1);
}
// fallback: try to extract any year
const yearMatch = dateStr.match(/\b(20\d{2})\b/);
if (yearMatch) {
return new Date(parseInt(yearMatch[1]), 0, 1);
}
return new Date(0);
return new Date(0);
}
const isDevMode = import.meta.env.PUBLIC_DEV === "1";
const projects: ProjectMetadata[] = Object.values(
import.meta.glob<AstroModule>("./projects/*.astro", { eager: true })
import.meta.glob<AstroModule>("./projects/*.astro", { eager: true }),
)
.map((module) => module.metadata)
.filter((metadata): metadata is ProjectMetadata => metadata !== undefined)
.filter((project) => !project.hidden || isDevMode)
.sort((a, b) => parseDate(b.date).getTime() - parseDate(a.date).getTime());
.map((module) => module.metadata)
.filter((metadata): metadata is ProjectMetadata => metadata !== undefined)
.filter((project) => !project.hidden || isDevMode)
.sort((a, b) => parseDate(b.date).getTime() - parseDate(a.date).getTime());
const allTags = new Set<string>();
projects.forEach((project) => {
project.tags?.forEach((tag) => allTags.add(tag));
project.tags?.forEach((tag) => allTags.add(tag));
});
const sortedTags = Array.from(allTags).sort((a, b) => a.localeCompare(b));

View File

@@ -1,6 +1,6 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "factor-e",

View File

@@ -1,6 +1,6 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "flackie",
@@ -11,15 +11,7 @@ export const metadata = {
image: "/flackie-icon.svg",
github: "https://github.com/hex248/flackie",
hidden: true,
tags: [
"Raspberry Pi",
"Python",
"C++",
"CMake",
"Electronics",
"Pillow",
"Image Generation",
],
tags: ["Raspberry Pi", "Python", "C++", "CMake", "Electronics", "Pillow", "Image Generation"],
type: "personal",
};
---

View File

@@ -1,6 +1,6 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "glimpse",
@@ -11,15 +11,7 @@ export const metadata = {
url: "https://glimpse.ob248.com",
github: "https://github.com/hex248/glimpse",
hidden: false,
tags: [
"Web",
"React",
"TypeScript",
"PostgreSQL",
"Blob Storage",
"Databases",
"OAuth2",
],
tags: ["Web", "React", "TypeScript", "PostgreSQL", "Blob Storage", "Databases", "OAuth2"],
type: "personal",
};
---

View File

@@ -1,29 +1,18 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "good morning!",
description:
"An app for couples or friends to share daily notices with songs and photos",
date: "October 2025",
slug: "good-morning",
image: "/good-morning-icon.png",
url: "https://gm.ob248.com",
github: "https://github.com/hex248/good-morning",
hidden: false,
tags: [
"Web",
"React",
"TypeScript",
"Go",
"PostgreSQL",
"AWS S3",
"Databases",
"OAuth2",
"Spotify API",
],
type: "personal",
title: "good morning!",
description: "An app for couples or friends to share daily notices with songs and photos",
date: "October 2025",
slug: "good-morning",
image: "/good-morning-icon.png",
url: "https://gm.ob248.com",
github: "https://github.com/hex248/good-morning",
hidden: false,
tags: ["Web", "React", "TypeScript", "Go", "PostgreSQL", "AWS S3", "Databases", "OAuth2", "Spotify API"],
type: "personal",
};
---

View File

@@ -1,27 +1,18 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "Issue",
description:
"A simple project management tool for developers. Born out of frustration with Jira.",
date: "December 2025 - Present",
slug: "issue",
image: "/issue-icon.svg",
url: "https://issue.ob248.com",
github: "https://github.com/hex248/issue",
hidden: false,
tags: [
"Web",
"React",
"TypeScript",
"Tauri",
"PostgreSQL",
"Databases",
"Bun",
],
type: "personal",
title: "Issue",
description: "A simple project management tool for developers. Born out of frustration with Jira.",
date: "December 2025 - Present",
slug: "issue",
image: "/issue-icon.svg",
url: "https://issue.ob248.com",
github: "https://github.com/hex248/issue",
hidden: false,
tags: ["Web", "React", "TypeScript", "Tauri", "PostgreSQL", "Databases", "Bun"],
type: "personal",
};
---

View File

@@ -1,23 +1,15 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "MIZU",
description:
"A discord bot card trading and collection game. (Currently inactive, 4000+ players) ",
description: "A discord bot card trading and collection game. (Currently inactive, 4000+ players) ",
date: "2021 - 2024",
slug: "mizu",
image: "/mizu-icon.svg",
hidden: false,
tags: [
"Node.js",
"TypeScript",
"PostgreSQL",
"AWS S3",
"Discord API",
"Database",
],
tags: ["Node.js", "TypeScript", "PostgreSQL", "AWS S3", "Discord API", "Database"],
type: "personal",
};
---

View File

@@ -1,6 +1,6 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "PrayerBud",

View File

@@ -1,11 +1,10 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "Shleep",
description:
"A couch co-op base defense game where you protect a sleepign child from nightmares.",
description: "A couch co-op base defense game where you protect a sleepign child from nightmares.",
date: "February - June 2023",
slug: "shleep",
image: "/shleep-icon.svg",

View File

@@ -1,26 +1,16 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "Watercooler",
description:
"Virtual office space for remote teams allowing quick questions and spontaneous chats.",
description: "Virtual office space for remote teams allowing quick questions and spontaneous chats.",
date: "March 2025",
slug: "watercooler",
image: "/watercooler-icon.svg",
// github: "https://github.com/hex248/watercooler",
hidden: true,
tags: [
"Web",
"React",
"TypeScript",
"WebRTC",
"LiveKit",
"PostgreSQL",
"OAuth2",
"Databases",
],
tags: ["Web", "React", "TypeScript", "WebRTC", "LiveKit", "PostgreSQL", "OAuth2", "Databases"],
type: "personal",
};
---

View File

@@ -1,6 +1,6 @@
---
import ProjectPage from "../../components/ProjectPage.astro";
import Demo from "../../components/Demo.astro";
import ProjectPage from "../../components/ProjectPage.astro";
export const metadata = {
title: "Wiskatron",

View File

@@ -263,12 +263,7 @@ body {
}
::selection {
background-color: rgba(
51,
136,
255,
0.25
); /* --ayu-selection with opacity */
background-color: rgba(51, 136, 255, 0.25); /* --ayu-selection with opacity */
color: var(--ayu-fg);
}

View File

@@ -1,14 +1,9 @@
{
"extends": "astro/tsconfigs/strict",
"include": [
".astro/types.d.ts",
"**/*"
],
"exclude": [
"dist"
],
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "react"
}
"extends": "astro/tsconfigs/strict",
"include": [".astro/types.d.ts", "**/*"],
"exclude": ["dist"],
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "react"
}
}