Voltar ao ranking

obsidianmd/obsidian-sample-plugin

TypeScriptdocs.obsidian.md

Template for Obsidian community plugins with build configuration and development best practices.

obsidianobsidian-mdobsidian-pluginplugin
Crescimento de estrelas
Estrelas
4.4k
Forks
1.7k
Crescimento semanal
Issues
15
2k4k
jan. de 2023mar. de 2024mai. de 2025jul. de 2026
Artefatosnpmnpm install obsidian-sample-plugin
README

Obsidian Sample Plugin

This is a sample plugin for Obsidian (https://obsidian.md).

This project uses TypeScript to provide type checking and documentation. The repo depends on the latest plugin API (obsidian.d.ts) in TypeScript Definition format, which contains TSDoc comments describing what it does.

This sample plugin demonstrates some of the basic functionality the plugin API can do.

  • Adds a ribbon icon, which shows a Notice when clicked.
  • Adds a command "Open modal (simple)" which opens a Modal.
  • Adds a plugin setting tab to the settings page.
  • Registers a global click event and outputs a Notice on click.
  • Registers a global interval which logs 'setInterval' to the console.

First time developing plugins?

Quick starting guide for new plugin devs:

  • Check if someone already developed a plugin for what you want! There might be an existing plugin similar enough that you can partner up with.
  • Make a copy of this repo as a template with the "Use this template" button (login to GitHub if you don't see it).
  • Clone your repo to a local development folder. For convenience, you can place this folder in your .obsidian/plugins/your-plugin-name folder.
  • Install NodeJS, then run npm i in the command line under your repo folder.
  • Run npm run dev to compile your plugin from src/main.ts to main.js.
  • Make changes to src/main.ts (or create new .ts files). Those changes should be automatically compiled into main.js.
  • Reload Obsidian to load the new version of your plugin.
  • Enable plugin in settings window.
  • For updates to the Obsidian API run npm update in the command line under your repo folder.

Releasing new releases

  • Update your manifest.json with your new version number, such as 1.0.1, and the minimum Obsidian version required for your latest release.
  • Update your versions.json file with "new-plugin-version": "minimum-obsidian-version" so older versions of Obsidian can download an older version of your plugin that's compatible.
  • Create new GitHub release using your new version number as the "Tag version". Use the exact version number, don't include a prefix v. See here for an example: https://github.com/obsidianmd/obsidian-sample-plugin/releases
  • Upload the files manifest.json, main.js, styles.css as binary attachments. Note: The manifest.json file must be in two places, first the root path of your repository and also in the release.
  • Publish the release.

You can simplify the version bump process by running npm version patch, npm version minor or npm version major after updating minAppVersion manually in manifest.json. The command will bump version in manifest.json and package.json, and add the entry for the new version to versions.json

Adding your plugin to the community plugin list

How to use

  • Clone this repo.
  • Make sure your NodeJS is at least v18 (node --version).
  • npm i to install dependencies.
  • npm run dev to start compilation in watch mode.

Manually installing the plugin

  • Copy over main.js, styles.css, manifest.json to your vault VaultFolder/.obsidian/plugins/your-plugin-id/.

Improve code quality with eslint

  • ESLint is a tool that analyzes your code to quickly find problems. You can run ESLint against your plugin to find common bugs and ways to improve your code.
  • This project already has eslint preconfigured, you can invoke a check by runningnpm run lint
  • Together with a custom eslint plugin for Obsidan specific code guidelines.
  • A GitHub action is preconfigured to automatically lint every commit on all branches.

Funding URL

You can include funding URLs where people who use your plugin can financially support it.

The simple way is to set the fundingUrl field to your link in your manifest.json file:

{
	"fundingUrl": "https://buymeacoffee.com"
}

If you have multiple URLs, you can also do:

{
	"fundingUrl": {
		"Buy Me a Coffee": "https://buymeacoffee.com",
		"GitHub Sponsor": "https://github.com/sponsors",
		"Patreon": "https://www.patreon.com/"
	}
}

API Documentation

See https://docs.obsidian.md

Repositórios relacionados
laurent22/joplin

Joplin - the privacy-focused note taking app with sync capabilities for Windows, macOS, Linux, Android and iOS.

TypeScriptnpmOtherreact-nativenodejs
joplinapp.org
55.7k6.2k
kepano/obsidian-skills

Agent skills for Obsidian. Teach your agent to use Obsidian CLI and open formats including Markdown, Bases, JSON Canvas.

MIT Licenseclaudecodex
42.9k3.1k
khoj-ai/khoj

Your AI second brain. Self-hostable. Get answers from the web or your docs. Build custom agents, schedule automations, do deep research. Turn any online or local LLM into your personal, autonomous AI (gpt, claude, gemini, llama, qwen, mistral). Get started - free.

PythonPyPIGNU Affero General Public License v3.0semantic-searchemacs
khoj.dev
35.9k2.3k
PDFMathTranslate/PDFMathTranslate

[EMNLP 2025 Demo] PDF scientific paper translation with preserved formats - 基于 AI 完整保留排版的 PDF 文档全文双语翻译,支持 Google/DeepL/Ollama/OpenAI 等服务,提供 CLI/GUI/MCP/Docker/Zotero

PythonPyPIGNU Affero General Public License v3.0chineselatex
pdf2zh.com
35.7k3.2k
obsidianmd/obsidian-releases

Community plugins list, theme list, and releases of Obsidian.

obsidian-mdobsidian
obsidian.md
20.1k7.4k
Byaidu/PDFMathTranslate

PDF scientific paper translation with preserved formats - 基于 AI 完整保留排版的 PDF 文档全文双语翻译,支持 Google/DeepL/Ollama/OpenAI 等服务,提供 CLI/GUI/Docker/Zotero

PythonPyPIGNU Affero General Public License v3.0chineselatex
pdf2zh.com
18.3k1.5k
YishenTu/claudian

An Obsidian plugin that embeds Claude Code/Codex as an AI collaborator in your vault

TypeScriptnpmMIT Licenseclaude-codeobsidian
14.2k913
jackyzha0/quartz

🌱 a fast, batteries-included static-site generator that transforms Markdown content into fully functional websites

TypeScriptnpmMIT Licensedigital-gardenobsidian-md
quartz.jzhao.xyz
12.8k4k
Vinzent03/obsidian-git

Integrate Git version control with automatic commit-and-sync and other advanced features in Obsidian.md

TypeScriptnpmMIT Licenseobsidian-mdobsidian-plugin
11.6k602
AgriciDaniel/claude-obsidian

Self-organizing AI second brain for Obsidian + Claude Code. Drop any source and Claude reads, links, and files it into one connected knowledge graph of plain Markdown you own. AI note-taking, personal knowledge management (PKM), and an open-source Notion alternative. Based on Karpathy's LLM Wiki pattern.

PythonPyPIMIT Licenseclaude-codeobsidian
agricidaniel.com/blog/claude-obsidian-ai-second-brain
9.8k1.1k
kmaasrud/awesome-obsidian

🕶️ Awesome stuff for Obsidian

CSSnpmCreative Commons Zero v1.0 Universalawesomeobsidian
9.2k386
kepano/defuddle

Get the main content of any page as Markdown.

TypeScriptnpmMIT Licensedefuddlecli
defuddle.md
8.5k362