My Obsidian Plugin
unlistedby Your Name
A starter Obsidian plugin with settings, commands, and ribbon icons.
Updated 18d agoMIT
Obsidian Plugin Starter
A production-ready Obsidian plugin template with TypeScript, esbuild hot reload, settings tab, commands, modals, and ribbon icons.
Features
- TypeScript — Full type safety with the Obsidian API
- esbuild — Fast builds with hot reload in dev mode
- Settings Tab — Configurable greeting, ribbon toggle, date format
- 5 Commands — Greeting, timestamp insert, modal, word count, checkbox toggle
- Ribbon Icon — Quick-access sidebar button
- Status Bar — Plugin status indicator
- File Events — Hooks into workspace file-open events
- Modal — Sample modal for building custom UI
Quick Start
# Install dependencies
npm install
# Development (watch mode with hot reload)
npm run dev
# Production build
npm run build
Development Setup
- Clone this repo into your vault's
.obsidian/plugins/directory - Run
npm install - Run
npm run dev - Enable the plugin in Obsidian → Settings → Community Plugins
- Edit
src/main.tsand changes will rebuild automatically
Commands
| Command | Description |
|---|---|
| Show greeting | Displays your configured greeting message |
| Insert timestamp | Inserts today's date at cursor position |
| Open sample modal | Opens an example modal dialog |
| Count words | Counts words in the current file |
| Toggle checkbox | Toggles - [ ] / - [x] on the current line |
Project Structure
├── src/
│ └── main.ts # Plugin entry point (commands, settings, modal)
├── styles.css # Plugin styles (auto-loaded by Obsidian)
├── manifest.json # Obsidian plugin manifest
├── versions.json # Version compatibility map
├── esbuild.config.mjs # Build configuration
├── version-bump.mjs # Auto-bumps manifest on npm version
├── tsconfig.json # TypeScript config
└── package.json
Customization
- Update
manifest.jsonwith your plugin ID, name, and author - Edit
src/main.tsto add your own commands, views, and logic - Add styles in
styles.css - Update
minAppVersioninmanifest.jsonif you use newer Obsidian APIs
Publishing
- Update version:
npm version patch/minor/major - Build:
npm run build - Create a GitHub release with
main.js,manifest.json, andstyles.css - Submit to Obsidian Community Plugins
Resources
License
MIT
For plugin developers
Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.