Search

Search articles, pages, topics, and people.

Analog User Guide - Content Model

ByHaozhe ZhuPublished on

Each site stores its content in one directory under sites. Posts, pages, authors, and the optional homepage introduction use MDX. Structured site data can live in TypeScript modules, while the people directory uses YAML.

For the demo site:

Text
sites/demo/
โ”œโ”€โ”€ _posts/
โ”œโ”€โ”€ _pages/
โ”œโ”€โ”€ _authors/
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ news/
โ”œโ”€โ”€ home-intro.mdx
โ””โ”€โ”€ people.yml

Content types

ContentSourceExample URLRequired
Posts_posts/**/*.mdx/post/notes/hello-worldNo
Pages_pages/**/*.mdx/aboutNo
Authors_authors/*.mdx/author/your-nameNo
Homepage introductionhome-intro.mdx/No
News_pages/news.mdx/newsNo
News datasrc/news/*.tsUsed by the homepage/pageNo
Peoplepeople.yml/peopleNo

Nested directories are supported for posts and pages. Author MDX files are kept directly under _authors.

Common fields

Posts, pages, and author profiles share these fields:

YAML
title: Example Title
summary: A short description displayed near the page title.
comment: false
seo:
  description: An optional description used in metadata.
  noIndex: false

title and summary are required. When seo.description is omitted, summary is also used for metadata. Set seo.noIndex to true when a page should not be indexed by search engines.

The examples below focus on content structure. Markdown syntax and rendering are demonstrated in Markdown Basic Syntax.

Posts

Posts are stored anywhere below _posts. Their URL follows the source path:

Text
_posts/hello-world.mdx        โ†’ /post/hello-world
_posts/notes/hello-world.mdx  โ†’ /post/notes/hello-world

A typical post begins with:

MDX
---
title: Hello World
summary: A short example post.
authors:
  - Your Name
datePublish: 2026-08-20
category: Notes
tags:
  - Next.js
  - MDX
cover: cover.jpg
---
 
Write the article here.
FieldRequiredDescription
titleYesPost title
summaryYesShort text displayed with the post
datePublishYesPublication date in YYYY-MM-DD format
categoryYesPrimary category
authorsNoInternal or external authors
dateUpdateNoLast update date
tagsNoList of tags
coverNoLocal or remote cover image
commentNoDefaults to true for posts
draftNoExcludes the post from normal production output
seoNoMetadata description and indexing preference

When dateUpdate is omitted, the build attempts to use the file's Git modification date and otherwise falls back to datePublish.

Internal and external authors

An author name written as a string refers to a profile under _authors:

YAML
authors:
  - Your Name

The name should match the title of the corresponding author profile.

An external author does not need a local profile:

YAML
authors:
  - name: Guest Author
    href: https://example.com

Categories and tags

Every post has one category and may have multiple tags:

YAML
category: Documentation
tags:
  - Next.js
  - MDX

Equivalent names can be combined through the aliases described in Site Configuration.

Local images

Keep images used only by one post in a directory beside its MDX file:

Text
_posts/notes/
โ”œโ”€โ”€ hello-world.mdx
โ””โ”€โ”€ hello-world/
    โ”œโ”€โ”€ cover.jpg
    โ””โ”€โ”€ diagram.png

Reference them by filename:

YAML
cover: cover.jpg
Markdown
![Architecture diagram](diagram.png)

Pages

Pages are stored below _pages and map directly to site routes:

Text
_pages/about.mdx             โ†’ /about
_pages/projects/example.mdx  โ†’ /projects/example

A minimal page looks like this:

MDX
---
title: About
summary: Background information about this site.
---
 
Write the page here.

Pages do not require publication dates, categories, or tags. They support draft, comment, and seo when needed.

Some paths are reserved by built-in application routes. A conflicting page path is reported during the build.

Authors

Author profiles are top-level MDX files under _authors:

Text
_authors/
โ”œโ”€โ”€ your-name.mdx
โ””โ”€โ”€ your-name/
    โ””โ”€โ”€ avatar.jpg

For example:

MDX
---
title: Your Name
summary: Researcher and software developer.
avatar: avatar.jpg
info:
  - label: Role
    value: Researcher
  - label: Affiliation
    value: Example University
socials:
  - label: GitHub
    href: https://github.com/your-name
    icon: IconBrandGithub
---
 
Write a short biography here.

This profile is available at /author/your-name. Posts that list Your Name as an internal author are connected to it and may appear in the profile's recent-articles section.

The info list contains label-value pairs. The socials list contains external links and Tabler icon names.

Homepage

The homepage hero and section order are configured under home in site.config.ts. Three section types are available:

  • news displays the supplied news items;
  • research lists structured research areas;
  • posts uses selected post slugs or the globally sorted post collection.

The optional home-intro.mdx body becomes the hero introduction and supports ordinary Markdown:

MDXsites/demo/home-intro.mdx
I work on **efficient computing systems** for emerging applications.
 
This site collects publications, projects, and technical notes.

When the file is omitted, the hero is rendered without an introduction. Homepage configuration options are described in Site Configuration.

News

News is an ordinary user page, so its layout can combine Markdown headings, prose, and reusable MDX components. The demo keeps structured entries in TypeScript modules grouped by year:

TypeScriptsites/demo/src/news/news-2026.ts
import { type InputNewsItem } from "@/lib/config"
 
export const news2026 = [
  {
    date: "2026-08-20",
    type: "publication",
    title: "A new paper has been published",
    description: "The paper is now available online.",
  },
] satisfies InputNewsItem[]

date and title are required for each entry. description and type are optional.

The supported types are publication, talk, project, award, people, and event. Timeline preserves the declared order, so keep entries and yearly exports in the order they should appear.

Create _pages/news.mdx and pass each group to the built-in Timeline component:

MDXsites/demo/_pages/news.mdx
---
title: News
summary: Recent updates, publications, and events.
---
 
import { news2026 } from "../src/news"
 
## 2026
 
<Timeline items={news2026} />

Relative imports are resolved from the MDX file. Because News uses the normal page model, its frontmatter supports the same comment, draft, and seo fields as other pages. To reuse the same entries on the homepage, export a combined array from src/news/index.ts and provide it to the homepage news section in site.config.ts.

See the demo news page and news data modules for a complete example.

People

The optional people.yml file creates a directory of current members and alumni:

YAMLsites/demo/people.yml
title: People
summary: Current members and alumni of the group.
 
current:
  Faculty:
    - name: Example Professor
      startYear: 2020
      research:
        - Human-computer interaction
      avatar: example-professor.jpg
      github: example
      author: example-professor
 
  Students:
    - name: Example Student
      startYear: 2024
      research:
        - Web systems
 
alumni:
  Former Students:
    - name: Example Alumnus
      startYear: 2020
      endYear: 2024
      description: Now working as a software engineer.

The keys below current and alumni become group headings and may be chosen freely.

Current members require name, startYear, and at least one research entry. Alumni require name, startYear, and endYear.

The optional author field links a person to an author-profile slug, while github accepts a GitHub username. Avatar and profile information can then be reused where available.

See the complete demo people file for additional groups and entries.

Content errors

Content is checked during development and production builds. Missing required fields, invalid dates, unknown references, and conflicting routes are reported with the affected file whenever possible.

Site-wide defaults, taxonomy aliases, and comments are configured separately in Site Configuration.