mirror of
https://git.aramjonghu.nl/AramJonghu/aramjonghu-site.git
synced 2026-06-06 17:18:24 +02:00
minor changes: (faulty)
This commit is contained in:
@@ -13,6 +13,9 @@
|
|||||||
"@tailwindcss/vite": "^4.2.2",
|
"@tailwindcss/vite": "^4.2.2",
|
||||||
"react": "^19.2.4",
|
"react": "^19.2.4",
|
||||||
"react-dom": "^19.2.4",
|
"react-dom": "^19.2.4",
|
||||||
|
"react-markdown": "^10.1.0",
|
||||||
|
"remark": "^15.0.1",
|
||||||
|
"remark-html": "^16.0.1",
|
||||||
"tailwindcss": "^4.2.2"
|
"tailwindcss": "^4.2.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
Binary file not shown.
@@ -0,0 +1,31 @@
|
|||||||
|
import { useEffect, useState } from "react";
|
||||||
|
import ReactMarkdown from "react-markdown";
|
||||||
|
|
||||||
|
const fetchREADME = async (url) => {
|
||||||
|
try {
|
||||||
|
const response = await fetch(url);
|
||||||
|
if (!response.ok) throw new Error("Failed to fetch README");
|
||||||
|
return await response.text();
|
||||||
|
} catch (error) {
|
||||||
|
console.error(error);
|
||||||
|
return "Error fetching README.";
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
export default function ProjectsReadme() {
|
||||||
|
const [readmeContent, setReadmeContent] = useState("");
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
fetchREADME(
|
||||||
|
// "https://git.aramjonghu.nl/AramJonghu/aramjonghu-site/src/branch/master/README.md",
|
||||||
|
"../../../README.md",
|
||||||
|
).then((content) => setReadmeContent(content));
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<h2>README Content</h2>
|
||||||
|
<ReactMarkdown>{readmeContent}</ReactMarkdown>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -1,13 +1,13 @@
|
|||||||
import { useState } from "react";
|
import { useState } from "react";
|
||||||
|
import ProjectsReadme from "../components/ProjectsReadme";
|
||||||
|
|
||||||
export default function Home() {
|
export default function Home() {
|
||||||
const [active, setActive] = useState("projects");
|
const [active, setActive] = useState("projects");
|
||||||
|
|
||||||
const sections = [
|
const sections = [
|
||||||
{
|
{
|
||||||
id: "projects",
|
id: "projects",
|
||||||
title: "Projects",
|
title: "Projects",
|
||||||
content: "Project content",
|
content: <ProjectsReadme />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "systems",
|
id: "systems",
|
||||||
@@ -25,19 +25,16 @@ export default function Home() {
|
|||||||
<div className="text-ctp-text flex flex-col items-center justify-center px-6 py-6">
|
<div className="text-ctp-text flex flex-col items-center justify-center px-6 py-6">
|
||||||
<div className="w-full max-w-6xl text-center">
|
<div className="w-full max-w-6xl text-center">
|
||||||
<h1 className="text-4xl font-bold text-ctp-mauve">
|
<h1 className="text-4xl font-bold text-ctp-mauve">
|
||||||
Aram Jonghu
|
AramJonghu
|
||||||
</h1>
|
</h1>
|
||||||
|
|
||||||
<p className="mt-4">
|
<p className="mt-4">
|
||||||
Software engineer building systems, services, and
|
Software engineer building systems, services, and
|
||||||
experiments across a self-hosted environment.
|
experiments across a self-hosted environment.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p className="mt-3">
|
<p className="mt-3">
|
||||||
This site acts as a hub for projects, infrastructure, and
|
This site acts as a hub for projects, infrastructure, and
|
||||||
personal tooling.
|
personal tooling.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<div className="mt-10 border rounded p-4">
|
<div className="mt-10 border rounded p-4">
|
||||||
<div className="flex flex-wrap justify-center gap-12">
|
<div className="flex flex-wrap justify-center gap-12">
|
||||||
{sections.map((section) => (
|
{sections.map((section) => (
|
||||||
@@ -52,7 +49,6 @@ export default function Home() {
|
|||||||
</button>
|
</button>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="mt-6 text-left relative min-h-20">
|
<div className="mt-6 text-left relative min-h-20">
|
||||||
{sections.map((section) => (
|
{sections.map((section) => (
|
||||||
<div
|
<div
|
||||||
@@ -66,7 +62,7 @@ export default function Home() {
|
|||||||
<h2 className="text-2xl font-bold text-ctp-mauve">
|
<h2 className="text-2xl font-bold text-ctp-mauve">
|
||||||
{section.title}
|
{section.title}
|
||||||
</h2>
|
</h2>
|
||||||
<p>{section.content}</p>
|
<div>{section.content}</div>{" "}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user