‼️‼️ IMPORTANT
This extension is used to create widgets with this tool: HtmlWidgetsRust.
📦 YTML Language Support – VS Code Extension
Language support for YTML , a simplified XML/HTML-based format used to build desktop widgets, panels, and UI components.
This extension provides:
- 🎨 Syntax Highlighting
- 🔍 Real-time Validation (Diagnostics)
- ⚠️ Built-in YTML rules
- ✨ Snippets for fast development
- 📄 Automatic detection of
.ytml files
Perfect for projects that use YTML as a widget-based UI definition language.
🚀 Features
✔️ Syntax Highlighting
Based on text.html.basic, extended with YTML-specific tags:
config
window
decorations
resizable
transparent
body
div
button
✔️ Real-time Validation
The built-in validator checks several structural rules:
🔸 <body> is required
If missing, an error is displayed.
Invalid example:
Diagnostic:
🔸 Only one <config> block is allowed
Prevents configuration conflicts.
✔️ Snippets Included
window snippet:
button snippet:
📁 Project Structure
🛠️ Installation (Development Mode)
- Clone the repository:
- Install dependencies:
- Compile the extension:
- Open the project in VS Code:
- Run the extension:
🧪 Testing with a .ytml File
Create a file named test.ytml:
You will see:
- Syntax highlighting
- Diagnostics for invalid structures
- Snippet suggestions
- Auto-closing tags
YTML is designed to describe desktop widget layouts in a concise, human-readable way — combining familiar HTML structure with strict UI configuration blocks.