Skip to main content
The blog uses a powerful markdown processing pipeline with custom Spotify-themed styling applied to all HTML elements.

Markdown Pipeline

Blog posts are processed through this pipeline:
1

gray-matter

Parses YAML frontmatter and separates it from contentPackage: [email protected]
2

remark

Converts markdown to HTML using the remark processorPackage: [email protected]
3

remark-html

Compiles markdown to HTML with sanitization enabledPackage: [email protected]File: src/lib/blog.ts:84
4

Custom Styling

Applies Spotify-themed CSS classes via regex replacementFile: src/lib/blog.ts:106
HTML is sanitized for security (sanitize: true), so raw HTML tags in markdown are stripped out. Always use markdown syntax instead.

Supported Syntax

Headings

Markdown headings automatically receive Spotify-themed styling:
# Heading 1
## Heading 2
### Heading 3

Styling Applied

  • H1: Gradient text effect (green to light green), 4xl/5xl size
  • H2: Left border accent, background tint, 2xl/3xl size
  • H3: Subtle left border, 1xl/2xl size
File: src/lib/blog.ts:110
Use ## (H2) for main sections and ### (H3) for subsections. H1 is reserved for the post title.

Paragraphs

Standard paragraph text with enhanced readability:
This is a regular paragraph with enhanced spacing and readability.
It uses light font weight with wide tracking for a modern look.

Multiple paragraphs are separated with blank lines.
Styling: Light font weight, wide tracking, responsive text sizing (sm/base/lg) File: src/lib/blog.ts:129

Emphasis

**Bold text** gets special styling with a subtle background and left border.

*Italic text* appears in Spotify green with an underline effect.

Bold Text

Receives a gradient background with left border accent: File: src/lib/blog.ts:160

Italic Text

Displayed in Spotify green with an animated underline: File: src/lib/blog.ts:166 Links are automatically styled with different treatments for internal vs external:
[Link to another page](/introduction)

[External link](https://example.com)

[Email link](mailto:[email protected])

Styling Features

  • Spotify green color with hover animation
  • Underline decoration with offset
  • Hover background tint
  • External links open in new tab with rel="noopener noreferrer"
File: src/lib/blog.ts:135

Code

Two types of code formatting:

Inline Code

Use `inline code` for short snippets and variable names.
Styling: Dark background, green text, border, monospace font File: src/lib/blog.ts:154

Code Blocks

```typescript
function example() {
  return "Hello World";
}
```
Styling:
  • Black background with transparency
  • Rounded corners with border
  • Green glow shadow effect
  • Horizontal scroll for long lines
File: src/lib/blog.ts:147
Syntax highlighting is not currently supported. Code blocks display in monospace with Spotify green text.

Lists

Both ordered and unordered lists are supported:
- Unordered item 1
- Unordered item 2
  - Nested item
  
1. Ordered item 1
2. Ordered item 2
3. Ordered item 3
Styling:
  • Custom green bullet points with glow effect
  • Enhanced spacing between items
  • Responsive text sizing
File: src/lib/blog.ts:179

Blockquotes

Blockquotes receive special Spotify-inspired treatment:
> This is a blockquote with enhanced styling.
> It can span multiple lines.
Styling Features:
  • Left border accent in Spotify green
  • Gradient background fade
  • Decorative opening quote mark
  • Italic text with shadow
File: src/lib/blog.ts:172 Real Example from: src/content/blog/openai-townhall.md:23
_"When people talk about traveling to the past, they worry about radically 
changing the present by doing something small, but barely anyone in the 
present really thinks that they can radically change the future by doing 
something small"_, quote from [just-shower-thoughts](...).

Images

Images are enhanced with figure captions and hover effects:
![Alt text describing the image](/images/blog/my-image.jpeg)
Styling Features:
  • Rounded corners with shadow
  • Hover zoom animation (scale 1.05)
  • Figure caption from alt text
  • Lazy loading for performance
  • Max width constraint for readability
File: src/lib/blog.ts:193 Real Examples from: src/content/blog/intern-experience-aws.md
![Office view](/images/blog/nitro.jpeg)

![Olympic National Park](/images/blog/olympic.jpeg)

![Where my project sits in the system](/images/blog/project.png)

![Mt. Rainier](/images/blog/rainier.jpeg)
Write descriptive alt text - it becomes the visible caption below the image!

Horizontal Rules

Create visual breaks with horizontal rules:
---
Styling: Gradient line with glow effect, centered with spacing File: src/lib/blog.ts:187

Unsupported Features

The following markdown features are not supported due to HTML sanitization:
  • Raw HTML tags (use markdown instead)
  • HTML comments
  • Custom CSS classes or styles
  • JavaScript or script tags
  • iframes or embedded content
  • Tables (not styled, but rendered as basic HTML)
Always use standard markdown syntax. Raw HTML will be stripped during processing.

Custom Styling System

The applyCustomStyling() function uses regex to transform HTML: File: src/lib/blog.ts:106
function applyCustomStyling(html: string): string {
  let styledHtml = html;

  // Example: Style H2 headings
  styledHtml = styledHtml.replace(
    /<h2>/g,
    '<div class="pt-8 pb-1"><h2 class="text-2xl md:text-3xl font-bold text-white mb-4 tracking-tight border-l-4 border-spotify-green pl-4 bg-spotify-light-dark/30 py-3 rounded-r-lg">'
  );
  styledHtml = styledHtml.replace(/<\/h2>/g, "</h2></div>");

  return styledHtml;
}

Design System

The styling uses these Tailwind CSS custom colors:
Color VariableHex ValueUsage
spotify-green#1DB954Primary accent, links, borders
spotify-white#FFFFFFText with opacity variations
spotify-light-darkDark grayCard backgrounds
spotify-darkVery darkMain background

Writing Best Practices

1

Use semantic markdown

Stick to standard markdown syntax for best results. Avoid HTML hacks.
2

Write descriptive alt text

Image alt text becomes the visible caption, so make it meaningful.
3

Structure with headings

Use H2 for main sections, H3 for subsections. Don’t skip heading levels.
4

Break up long text

Use images, quotes, lists, and code blocks to add visual variety.
5

Test in development

Always preview your post locally before deploying to catch formatting issues.

Real-World Examples

Examine these posts to see markdown in action:

OpenAI Townhall

src/content/blog/openai-townhall.mdGreat example of:
  • Opening quote
  • Personal narrative
  • Multiple images
  • External links

AWS Internship

src/content/blog/intern-experience-aws.mdFeatures:
  • H2/H3 structure
  • Technical content
  • Mixed media
  • Emphasis usage

Dependencies

The markdown system relies on these packages: File: package.json:17
{
  "dependencies": {
    "gray-matter": "^4.0.3",
    "remark": "^15.0.1",
    "remark-html": "^16.0.1"
  }
}

Next Steps

Creating Posts

Learn how to write and publish new blog posts

Blog Overview

Understand the blog architecture and routing

Build docs developers (and LLMs) love