How to build and release your first Obsidian plugin
Wann einsetzen: You have a concrete workflow improvement and want a plugin in a day.
Voraussetzungen
- Node 18+ — nvm install 18
- A local vault for testing — Create a new Obsidian vault just for development
- Skill cloned — git clone https://github.com/gapmiss/obsidian-plugin-skill ~/.claude/skills/obsidian-plugin-skill
Ablauf
-
Scaffold the pluginScaffold an Obsidian plugin called 'smart-outline' with a command and a settings tab.✓ Kopiert→ Folder with manifest, main.ts, build config
-
Add the featureImplement: on command, open a modal showing the outline of the active note.✓ Kopiert→ Working modal reading from the active MarkdownView
-
Side-load and testInstall into the dev vault's plugins folder and reload Obsidian.✓ Kopiert→ Plugin shows up, command works
-
Prepare a releaseCreate versions.json and tag a v0.1.0 release.✓ Kopiert→ GitHub release with main.js + manifest.json attached
Ergebnis: A working, installable plugin you can submit to the Community store.
Fallstricke
- Forgetting versions.json — Community store rejects — Skill reminds; always keep it in sync with manifest.json
- Referencing Obsidian internals that aren't part of the API — Stick to the public API; treat internals as volatile