TeaLeaf Language Support for Visual Studio Code
Syntax highlighting and language support for the TeaLeaf format (.tl files).
Features
Installation
From VSIX (Local)
Package the extension:
cd vscode-tealeaf
npx vsce package
Install the .vsix file:
- Open VS Code
- Press
Ctrl+Shift+P and select "Extensions: Install from VSIX..."
- Select the generated
.vsix file
For Development
Copy or symlink this folder to your VS Code extensions directory:
- Windows:
%USERPROFILE%\.vscode\extensions\tealeaf-lang
- macOS/Linux:
~/.vscode/extensions/tealeaf-lang
Reload VS Code
Example
# Schema definitions
@struct Location (city: string, country: string)
@struct Person (
id: int,
name: string,
email: string?,
location: Location,
tags: []string,
)
# Data using schema
people: @table Person [
(1, "Alice", "alice@example.com", ("Seattle", "USA"), [admin, user])
(2, "Bob", ~, ("Austin", "USA"), [user])
]
# Simple values
config: {
debug: true,
timeout: 5000,
api_url: "https://api.example.com",
}
# References and tagged values
base: {host: localhost, port: 8080}
dev: !base
status: :ok 200
TeaLeaf is a schema-aware data format with:
- Human-readable text representation (
.tl)
- Compact binary representation (
.tlbx)
- Schema definitions with types
- String deduplication
- JSON interoperability
Learn more: TeaLeaf Specification
License
MIT