From f467e1cbb44f7b7d274fad0cecb2aa1c3c79f743 Mon Sep 17 00:00:00 2001 From: Bradley Shellnut Date: Thu, 20 Apr 2023 11:14:52 -0700 Subject: [PATCH] Update to show new website is in SvelteKit. --- .../personal/personal-website-gatsby.md | 31 ------------------- .../personal/personal-website-sveltekit.md | 25 +++++++++++++++ src/routes/portfolio/+page.server.ts | 27 ---------------- src/routes/portfolio/+page.svelte | 4 +-- 4 files changed, 27 insertions(+), 60 deletions(-) delete mode 100644 src/lib/content/portfolio/personal/personal-website-gatsby.md create mode 100644 src/lib/content/portfolio/personal/personal-website-sveltekit.md diff --git a/src/lib/content/portfolio/personal/personal-website-gatsby.md b/src/lib/content/portfolio/personal/personal-website-gatsby.md deleted file mode 100644 index b98511b..0000000 --- a/src/lib/content/portfolio/personal/personal-website-gatsby.md +++ /dev/null @@ -1,31 +0,0 @@ ---- -portfolioName: 'Personal Website' -portfolioSubHeading: 'My personal website written using the following technologies.' -portfolioImage: 'Bradley_Shellnut_New_Site.png' -portfolioImageAlt: 'Home Page of bradleyshellnut.com' ---- - - - -{portfolioSubHeading} - -Tech Stack: - -- React 18 -- Gatsby 5 -- Radix UI -- Styled Components -- GraphQL -- Deployed using Netlify -- Most icons from react-icons -- Bee, Shell, Nut, and Seattle Icons made by "Freepik" from flaticon.com - -Current version was improved after the suggestions on Show 444 of the Syntax Podcast. - -You can view the previous archived version of my personal website here. diff --git a/src/lib/content/portfolio/personal/personal-website-sveltekit.md b/src/lib/content/portfolio/personal/personal-website-sveltekit.md new file mode 100644 index 0000000..3ca0b98 --- /dev/null +++ b/src/lib/content/portfolio/personal/personal-website-sveltekit.md @@ -0,0 +1,25 @@ +--- +portfolioName: 'Personal Website' +portfolioSubHeading: 'My personal website re-written using SvelteKit.' +portfolioImage: 'Bradley_Shellnut_New_Site.png' +portfolioImageAlt: 'Home Page of bradleyshellnut.com' +--- + + + +{portfolioSubHeading} + +Tech Stack: + +- SvelteKit +- TypeScript +- Deployed on Vercel +- Bee, Shell, Nut, and Seattle Icons made by "Freepik" from flaticon.com + +Previous version of my website was written using React and Gatsby which you can view here. + +Each iteration brings better code and my previous React version was improved after the suggestions on Show 444 of the Syntax Podcast. + +You can view the previous archived version of the site before those changes here. diff --git a/src/routes/portfolio/+page.server.ts b/src/routes/portfolio/+page.server.ts index 230c200..189f71e 100644 --- a/src/routes/portfolio/+page.server.ts +++ b/src/routes/portfolio/+page.server.ts @@ -1,28 +1 @@ -import { error } from '@sveltejs/kit'; -import { compile } from 'mdsvex'; -import type { PageServerLoad } from '../$types'; export const prerender = true; - -export const load: PageServerLoad = async () => { - try { - const personalSiteGatsby = await import( - `../../lib/content/portfolio/personal/personal-website-gatsby.md` - ); - - const { default: page, metadata } = personalSiteGatsby; - - // const [personalSiteGatsbyResponse] = await Promise.all([personalSiteGatsby]); - - console.log(`page: ${JSON.stringify(page)}, metadata: ${JSON.stringify(metadata)}`); - - // const compiledResponse = await compile(personalSiteGatsbyResponse); - - // console.log(`compiledResponse is: ${JSON.stringify(compiledResponse)}`); - return { - portfolios: '' - }; - } catch (e) { - console.error(e); - throw error(500, 'Error loading portfolios'); - } -}; diff --git a/src/routes/portfolio/+page.svelte b/src/routes/portfolio/+page.svelte index c6194ab..76b101d 100644 --- a/src/routes/portfolio/+page.svelte +++ b/src/routes/portfolio/+page.svelte @@ -13,7 +13,7 @@ import weddingWebsite from "$lib/assets/images/Wedding_Website.png?run"; import oldSite from '$lib/assets/images/Old_Website_Bradley_Shellnut.png?run'; import shellnutArchitectWebsite from "$lib/assets/images/Mark_Shellnut_Architect.png?run"; - import PersonalWebsiteGatsby from "$lib/content/portfolio/personal/personal-website-gatsby.md"; + import PersonalWebsiteSvelteKit from "$lib/content/portfolio/personal/personal-website-sveltekit.md"; import WeddingWebsite from '$lib/content/portfolio/personal/wedding-website.md'; import MarkShellnutArchitect from '$lib/content/portfolio/professional/mark-shellnut-architect.md?run'; import OldWebsite from '$lib/content/portfolio/personal/old-website.md'; @@ -39,7 +39,7 @@ src={personalSite} loading="eager" alt="Picture of Bradley Shellnut's Gatsby Personal Website"> - +