Skip to content

Commit 07893b5

Browse files
committed
first pass at hero component; markdown code cleanup
1 parent 77c4446 commit 07893b5

16 files changed

Lines changed: 349 additions & 60 deletions

astro.config.mjs

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import react from '@astrojs/react';
66
import sitemap from '@astrojs/sitemap';
77
import tailwindcss from '@tailwindcss/vite';
88
import { defineConfig, fontProviders } from 'astro/config';
9+
import expressiveCode from 'astro-expressive-code';
910
import { FileSystemIconLoader } from 'unplugin-icons/loaders';
1011
import Icons from 'unplugin-icons/vite';
1112
import { siteConfig } from './src/lib/config.ts';
@@ -26,13 +27,19 @@ export default defineConfig({
2627
},
2728
{
2829
provider: fontProviders.bunny(),
29-
name: 'IBM Plex Serif',
30-
weights: [300, 400, 500, 600, 700],
31-
cssVariable: '--font-ibm-plex-serif',
30+
name: 'IBM Plex Mono',
31+
weights: [400],
32+
cssVariable: '--font-ibm-plex-mono',
3233
},
3334
],
3435
},
35-
36+
// markdown: {
37+
// shikiConfig: {
38+
// // Choose from Shiki's built-in themes (or add your own)
39+
// // https://shiki.style/themes
40+
// theme: 'catppuccin-frappe',
41+
// },
42+
// },
3643
vite: {
3744
// TODO #1 - remove expect error when Astro updates to Vite 7
3845
// https://github.com/withastro/astro/issues/14030#issuecomment-3027129338
@@ -50,6 +57,22 @@ export default defineConfig({
5057
],
5158
},
5259

53-
integrations: [react(), sitemap(), mdx()],
60+
integrations: [
61+
react(),
62+
sitemap(),
63+
// TODO: #1 make sure our mono font works with expressiveCode
64+
expressiveCode({
65+
themes: ['catppuccin-frappe'],
66+
defaultProps: {
67+
// Enable word wrap by default
68+
wrap: true,
69+
// Disable wrapped line indentation for terminal languages
70+
overridesByLang: {
71+
'bash,ps,sh': { preserveIndent: false },
72+
},
73+
},
74+
}),
75+
mdx(),
76+
],
5477
adapter: netlify(),
5578
});

package-lock.json

Lines changed: 218 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
"@types/react": "^19.2.6",
2424
"@types/react-dom": "^19.2.3",
2525
"astro": "^5.15.9",
26+
"astro-expressive-code": "^0.41.5",
2627
"canvas-confetti": "^1.9.3",
2728
"fuse.js": "^7.1.0",
2829
"marked": "^17.0.1",

src/components/organisms/Head.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ const imageURL = ogImage ? new URL(ogImage.src, Astro.url).href : undefined;
5858
<meta property="twitter:image" content={imageURL} />
5959

6060
<!-- Local Font Declaration -->
61-
<Font cssVariable="--font-ibm-plex-serif" preload />
61+
<Font cssVariable="--font-ibm-plex-mono" preload />
6262
<Font cssVariable="--font-inter" preload />
6363

6464
<!-- Additional head content -->

0 commit comments

Comments
 (0)