TLML - Turbo Lightweight Markup Language
A powerful VS Code extension that provides live preview and export functionality for TLML (.tlml) files.

Features
- 🚀 Live Preview - Real-time preview of your TLML documents with beautiful styling
- 📱 Side-by-Side Preview - Preview alongside your code in a split view
- 📤 Multi-Format Export - Export to HTML, Markdown, PDF, DOCX, EPUB, LaTeX, and more
- 🎨 Syntax Highlighting - Full syntax support for TLML with color coding
- ⚡ Fast Parsing - Optimized Python parser for quick rendering
- 🎯 Modern UI - Beautiful, responsive preview interface with animations
- 📝 Rich Formatting - Support for bold, italic, colors, sizes, and more
- 📊 Tables & Lists - Create beautiful tables and organized lists
- 🔗 Links & Media - Support for images, audio, video, and links
- 📚 Footnotes - Add reference footnotes to your documents
- 😊 Emojis - Use emoji shortcodes for expressive content
- 📋 Collapsibles - Create expandable sections for better organization
TLML Syntax
TLML (Turbo Lightweight Markup Language) is a simple yet powerful markup language:
Headings
/ Main Title
// Subtitle
/// Section
Text Formatting
%bold text%
^italic text^
~strike~
,inline code,
`backtick code`
Lists
_ Unordered item
_ Another item
1. Ordered item
2. Another ordered item
Blockquotes
> This is a blockquote
* Another blockquote style
Code Blocks
```python
def hello():
print("Hello, TLML!")
```
[Link text](https://example.com)
[[https://example.com|Link with label]]
 "Caption"
[audio](https://github.com/AtifaTahreem/tlml-preview/blob/HEAD/audio.mp3) "Audio title"
[video](https://github.com/AtifaTahreem/tlml-preview/blob/HEAD/video.mp4) "Video title"
Colors and Styling
[red]Red text[/red]
[#ff0000]Custom color[/#ff0000]
[size=20]Large text[/size]
Tables
/table
Header 1 | Header 2 | Header 3
Cell 1 | Cell 2 | Cell 3
Cell 4 | Cell 5 | Cell 6
/end
Collapsible Sections
+++ Summary
This content is collapsible
---
This has a footnote[^1]
[^1]: This is the footnote text
Emojis
:smile: :heart: :rocket: :star: :check: :warning: :bug: :coffee: :tada: :sparkles:
: This line is a comment and won't appear in the output
Collapsible Sections (Alternative)
/collapse Summary
This content is collapsible
/end
Quick Example
Here's a complete TLML document example:
/ My TLML Document
This is a **beautiful** TLML document with *rich formatting*.
// Features
_ Live preview
_ Export to HTML
_ Syntax highlighting
_ Modern styling
// Code Example
```python
def hello_tlml():
print("Hello, TLML World!")
return "Beautiful output"
```
// Styling
[red]This text is red[/red]
[size=20]This text is large[/size]
// Table
/table
Feature | Status
Preview | ✅ Working
Export | ✅ Working
/end
// Collapsible
+++ Click to expand
This content is hidden by default.
---
[^1]: This is a footnote reference.
TLML supports multiple export formats for maximum flexibility:
- HTML - Beautiful web-ready output with modern styling
- Markdown - Compatible with GitHub, GitLab, and other platforms
- Text - Plain text for simple documents
- LaTeX - Academic papers and professional documents
- PDF - High-quality PDF documents (requires
weasyprint
or reportlab
)
- DOCX - Microsoft Word documents (requires
python-docx
)
- EPUB - E-book format (requires
ebooklib
)
Export Usage
# Export all formats
TLML_EXPORT=1 python tlml_parser.py document.tlml
# Export specific formats
python tlml_parser.py --export html,pdf,docx document.tlml
Commands
TLML: Preview
- Open preview in current tab
TLML: Preview to Side
- Open preview in side panel
TLML: Export to HTML
- Export current document to HTML
Installation
- Install the extension from the VS Code marketplace
- Open any
.tlml
file (or create a new one)
- Use
Ctrl+Shift+P
and search for "TLML" commands
- Right-click in a
.tlml
file and select "TLML: Preview" from the context menu
Usage
- Create a TLML file: Create a new file with
.tlml
extension
- Write TLML content: Use the syntax examples above to write your content
- Preview: Use
Ctrl+Shift+P
→ "TLML: Preview" or "TLML: Preview to Side"
- Export: Use
Ctrl+Shift+P
→ "TLML: Export to HTML" to save as HTML
- Multi-format Export: Use the command line to export to multiple formats at once
Requirements
- Python 3.6+ (for the TLML parser)
- VS Code 1.90.0+
- Windows, macOS, or Linux
License
MIT License - see LICENSE.md for details.
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Author
Atifa Tahreem - GitHub