Syntax highlighting for .spec (Foundry DSL): XML-style tags plus Foundry comments (//, /* */, <!-- -->), line-leading Foundry keywords, and line-leading C#-style keywords (e.g. var, return, public, async) for script inside function / spec bodies. Full C# inside a line is not parsed (TextMate limits); use a .cs file or an LSP later if you need deeper coloring.
Diagnostics (red squiggles): mismatched or missing closing tags for XML-style elements (<Tag>…</Tag>, self-closing />), respecting Foundry comments and quoted / {…} attribute values. C-style comparisons in script (i < left, <=, <<) are not treated as XML tags; comparison detection uses same-line lookbehind so a // comment on the previous line cannot hide a real <Tag> on the next line.
Ctrl+Click navigation: include '…', XML-style content="…" / src="…", and script .SetAttribute("src", "/…") (absolute path under Assets or relative to the current file), when the target file exists on disk.
Install from a VSIX
Install VSCE if needed: npm install -g @vscode/vsce
From this directory (CoreHustlers/Tools/spec-links): vsce package
In Cursor/VS Code: Extensions → … → Install from VSIX… → select the generated .vsix.
Develop / debug the extension
Open the spec-links folder in Cursor/VS Code (or open the monorepo and use Run and Debug with this extension as the launch target).
Run → Start Debugging (F5) to open a new Extension Development Host window with this extension loaded.
Open a .spec file in the host window and use Developer: Inspect Editor Tokens and Scopes to verify scopes (e.g. comment.line.double-slash, keyword.control.foundry, XML tag scopes from text.xml).