iso27diy-corp/Corpus/Sparks/Using Obsidian.md

63 lines
3.9 KiB
Markdown

---
tags:
- type/howto
- obsidian
---
**MOC** stands for **Map of Content**, eq. Topic Notes
## Front Matter
**Front matter** (often called YAML front matter) refers to a block of metadata at the very beginning of a Markdown file (which is what Obsidian notes are). It's typically enclosed between two sets of triple dashes (`---`).
Here's what front matter is and why it's useful:
Markdown
```
---
title: My Awesome Note
tags: [knowledge-management, obsidian, moc]
date_created: 2025-06-07
status: draft
---
This is the content of my note...
```
- **Metadata:** Front matter allows you to store structured information (metadata) about your note in a standardized format (YAML - YAML Ain't Markup Language). This information isn't part of the visible content of the note but provides valuable context and data about it.
- **Key-Value Pairs:** It consists of key-value pairs. For example, `title: My Awesome Note` means "title" is the key and "My Awesome Note" is its value.
- **Common Uses:**
- **Tags:** Defining tags for categorization (e.g., `tags: [personal, project-x]`). While tags can also be used inline within the note, putting them in front matter makes them easily accessible for querying and filtering.
- **Aliases:** Providing alternative names for a note, which allows you to link to it using different terms (e.g., `aliases: [PKM, Personal Knowledge Management]`).
- **Dates:** Storing creation or modification dates (e.g., `date_created: 2025-06-07`).
- **Status/Type:** Indicating the status of a note (e.g., `status: draft`, `status: complete`) or its type (e.g., `type: book-summary`, `type: meeting-notes`).
- **Authors/Sources:** Attributing content or linking to source material.
- **Programmatic Access (e.g., Dataview):** The real power of front matter comes with plugins like Dataview. Dataview can read and query this metadata, allowing you to create dynamic tables, lists, and dashboards based on the properties defined in your notes' front matter. For instance, you could create a list of all "draft" notes or all notes related to a specific project.
- **Hidden in Reading View:** When you switch to "reading view" in Obsidian, the front matter block is typically hidden, providing a clean reading experience while still preserving the metadata for your system.
## Links in Frontmatter vs. main text
The choice between frontmatter and main text for internal links in Obsidian depends on the purpose and nature of the links:
Put links in frontmatter when:
- Creating structured metadata relationships (like tags, categories, or formal associations)
- Building MOCs (Maps of Content) or index pages where you want clean, scannable link lists
- Using plugins that specifically read frontmatter fields (like Dataview queries)
- Creating "up" links to parent topics or broader categories
- Setting up formal taxonomies or hierarchical relationships
Put links in main text when:
- The links are part of your natural writing flow and thinking process
- You're making contextual connections that relate to specific ideas or sentences
- The links represent your active thought process while writing
- You want the links to be part of your reading experience when reviewing notes
- The connections are discoveries or insights that emerged while writing
Hybrid approach:
Many Obsidian users combine both methods. For example, you might put formal category links in frontmatter (`parent: [[Project Management]]`) while keeping contextual, thought-based links in the body text where they naturally arise during writing.
The main text approach tends to be more organic and supports the "thinking in writing" philosophy that many note-takers prefer, while frontmatter links are better for systematic organization and plugin automation. Consider your primary use case: if you're building a knowledge system for later querying and analysis, lean toward frontmatter structure. If you're thinking through ideas and making connections as you write, embed them naturally in your text.