Contributions are welcome! Here's how to get started.
# Prerequisites: Node.js 18+, pnpm 10+
pnpm install
pnpm buildPress F5 in VS Code to launch a debug instance with the extension loaded.
src/ Extension host (Node.js) — VSCode API, file I/O
i18n/ Translation loader
utils/ Utility functions (nonce, image service)
webview/ WebView frontend (Browser) — Milkdown editor, UI components
components/ Reusable UI components (toolbar, table, toc, imageView, ...)
i18n/ Translation helpers t() / kbd()
ui/ Shared UI utilities (icons, tooltip)
i18n/ Localized resources
l10n/ VS Code l10n runtime strings
webview/ WebView translation files (JSON)
docs/ Localized documentation
We welcome translations for new languages! Here's how to contribute:
- Create a new JSON file in
i18n/webview/directory - Name the file using the language code (e.g.,
fr.jsonfor French,de.jsonfor German) - Copy the content from
i18n/webview/en.jsonas a template - Translate all values to your language
- Submit a Pull Request
{
"Table of Contents": "目次",
"Undo": "元に戻す",
"Redo": "やり直し",
...
}- Keys are in English (matching the code's
t('Bold')calls) - Values are the translated strings
- Keep the same key structure as
en.json
en.json- English (default)zh-cn.json- Chinese (Simplified)ja.json- Japaneseko.json- Korean
- Add your translation file to
i18n/webview/ - Run
pnpm build - Change VS Code language setting to your language
- Open a Markdown file and verify the translations
- TypeScript everywhere
- WebView ↔ Extension communication only through
webview/messaging.ts - CSS must use
--vscode-*variables for theme compatibility - Use
pnpm— notnpmoryarn - Git commit messages: type prefix in English, description in Chinese
- Fork the repository
- Create a branch from
dev:git checkout -b feature/your-feature - Make changes and run
pnpm buildto verify - Open a Pull Request against the
devbranch
Please use the Bug Report template and include your VS Code version and the Output panel logs.