Skip to main content

An Example Post

· 3 min read
Ozzy
Black Guy

Just a random post to show various mdx features

1. Image with a Caption

Here's an example of a single image with a caption:

Screenshot of a terminal window with 4-split panes, showing off colours, prompt and functionality

2. Two Images Side by Side

Use the ImageWrapper component to display images side by side:

Picture showing a historical terminal; the keyboard and a display of a DEC VT100
Picture showing a modern terminal; a window with tabbed shells

3. Expandable Information Note

Use <details> and <summary> tags to create expandable sections:

Click to expand and see more information

Here's the hidden content that appears when you expand this section.

Screenshot of a terminal window with 4-split panes

You can include any content here:

  • Lists
  • Images
  • Code blocks
  • Links

4. Example Note

Use the :::note syntax to create informational notes:

note

This is a basic note.

Example

This is a note with a custom title.

tip

This is a tip! You can also use :::tip, :::warning, :::caution, and :::danger for different types of admonitions.

5. SVG Image

SVG images are handled the same way as regular images:

Example SVG or image file

6. Command Line Code

Display command-line code with syntax highlighting:

Bash Example

echo hello world

JSON Example

{
"lorem": {
"ipsum": {
"dolor": "sit amet",
"consectetur": "adipiscing elit",
"sed": {
"do": "eiusmod tempor",
"incididunt": 42
}
}
}
}

7. Table

Create tables using standard Markdown syntax:

Basic Table

LoremIpsumDolor Sit
consecteturadipiscing elit sed do
eiusmod temporincididunt ut labore
dolore magnaaliqua enim
minim veniamquis nostrud

Glossary Table

LoremIpsumDolor
Consectetur adipiscing / Elit sed / DoEiusmod tempor incididunt ut laboreDolore magna, Aliqua enim, Minim veniam, Quis, Nostrud
ExercitationUllamco laboris nisi ut aliquip ex ea commodo consequatDuis, Aute, Irure, Dolor, Reprehenderit
VoluptateVelit esse cillum dolore eu fugiat nulla pariaturExcepteur sint, Occaecat, Cupidatat, Non proident
CulpaQui officia deserunt mollit anim id est laborumSed perspiciatis, Unde omnis, Iste natus

8. Math Equations (KaTeX)

You can write beautiful math equations using KaTeX:

Inline Math

Write inline math by wrapping LaTeX equations between $:

Let f ⁣:[a,b]Rf\colon[a,b]\to\mathbb{R} be Riemann integrable. Let F ⁣:[a,b]RF\colon[a,b]\to\mathbb{R} be F(x)=axf(t)dtF(x)=\int_{a}^{x} f(t)\,dt. Then FF is continuous, and at all xx such that ff is continuous at xx, FF is differentiable at xx with F(x)=f(x)F'(x)=f(x).

Block Math

For display mode equations, use $$:

I=02πsin(x)dxI = \int_0^{2\pi} \sin(x)\,dx E=mc2E = mc^2

Conclusion

This example post demonstrates all the key MDX components you can use in your blog posts. Mix and match these elements to create engaging and informative content!