Welcome to the development guide for Obsidian Void. This document is your personal quickstart for testing, modifying, and publishing your theme.
Remember the core philosophy: focus and simplicity.
This folder contains all the necessary files for your color theme. The two most important files are:
package.json: This is the heart of your extension (the manifest file). It defines metadata like the theme's name, publisher, and points to the theme definition file.themes/obsidian-void-color-theme.json: This is where the magic happens. All your UI colors (colors) and syntax highlighting rules (tokenColors) are defined in this file.
Your theme comes with a pre-configured workflow to make testing easy and fast.
- Start Debugging: Press
F5in VS Code. - New Window Opens: A new "Extension Development Host" window will appear. This window has your Obsidian Void theme loaded as an active extension.
- Activate Your Theme: If not already active, use
Ctrl+K Ctrl+Tto open the theme picker and select "Obsidian Void". - Live Reload: Open the
themes/obsidian-void-color-theme.jsonfile in your main editor. Make any color change and save the file. The changes will be applied instantly in the Extension Development Host window. No reload needed!
To create a great theme, you need to know what to color. The "Inspect Editor Tokens and Scopes" tool is your best friend.
- In the Extension Development Host window, open any code file (e.g., a
.js,.py, or.cssfile). - Press
Ctrl+Shift+Pto open the Command Palette. - Run the
Developer: Inspect Editor Tokens and Scopescommand. - Click on any piece of code (a keyword, variable, string, etc.).
- An info box will appear, showing you the exact
scopefor that token (e.g.,keyword.control.js). You can then use this scope in thetokenColorssection of your.jsonfile to assign it a color.
Ready to share Obsidian Void with the world? The process is straightforward.
- Install
vsce: If you haven't already, install the Visual Studio Code Extension manager globally:npm install -g @vscode/vsce
- Package Your Extension: This will create a
.vsixfile, which is your packaged extension.vsce package
- Publish: To publish, you first need a publisher account on the VS Code Marketplace. Once set up, you can publish your theme.
vsce publish
For detailed, one-time setup instructions (like creating a publisher), refer to the official Publishing Extensions documentation.
Happy coding!
