Cold Start Path (Obsidian starting up)
2nd resolved Event
resolvedLinks fully populated.
→ finalizeLinks()
→ Rebuild: backlinks (body/fm), unresolved, embeds
Per-file resolve
resolvedLinks populated
incremental per file
→ updateFileLinks() fires
1st resolved Event
getFileCache() now works.
resolvedLinks may still be empty.
→ initializeAndWaitForLinks()
→ Build: tags, headings, frontmatter, aliases, blocks, tasks
Completion Gate
Waits for BOTH:
✓ initializeAndWaitForLinks done
✓ 2nd resolved fired
ready Event
All indexes complete. Safe to query.
Wait for Events
Subscribe to resolved event
Wait for MetadataCache
Check resolvedLinks
Are links already populated? (late activation check)
Constructor
Calls waitForMetadataCacheThenInitialize()
Registers event handlers
Late Activation
Single-pass initialize()
All data available immediately