DEV Community

Daniel Jonathan
Daniel Jonathan

Posted on

🧩 Debugging XSLT Made Easy in VS Code: .NET-Based Debugging for Logic Apps

Debugging XSLT has always been a challenge β€” especially when you're trying to understand why a transformation doesn't behave as expected. That's why I built XSLT Debugger, a .NET-based Visual Studio Code extension that brings real debugging support for XSLT stylesheets.


πŸš€ What It Does

This extension lets you:

  • Set breakpoints in .xslt files
  • Step through transformations (step over, step into, continue)
  • Auto-capture XSLT variables β€” All inline variables appear automatically in the Variables panel
  • Watch nodes and variables β€” Add custom watches for XPath expressions and context nodes
  • Capture and view xsl:message output
  • Debug with .NET engine (XSLT 1.0, matching Azure Logic Apps) or Saxon (XSLT 2.0/3.0)
  • Support for msxsl:script C# extensions (step-through skipped for embedded C#)

βš™οΈ Getting Started

  1. Install XSLT Debugger from VS Code Marketplace
  2. Update .vscode/launch.json with your XSLT and XML file paths
  3. Open your .xslt and .xml files
  4. Press F5 β†’ Start Debugging

Configuration Settings

That's it β€” you can now set breakpoints, run step-by-step, and finally see what's happening in your transformations.

πŸ“¦ Sample files and launch configurations: GitHub Repository


🧩 Why It Matters

This extension brings modern debugging to XSLT development β€” something that's been missing for years, especially for Azure Logic Apps developers.

Debugging XSLT 1.0 with .NET Engine β€” Matches Azure Logic Apps production runtime:
XSLT 1.0 Debugging

Debugging XSLT 2.0/3.0 with Saxon β€” Variable tracking in action with Debug console, Variables panel, and Watch panel showing inline XSLT variables:
XSLT 2.0/3.0 Debugging

Whether you're maintaining legacy integrations or building new Logic Apps workflows, this extension makes XSLT development finally debuggable.


⚠️ Current Limitations

The debugger is designed to stay simple and stable, without attempting to fully parse complex XSLT constructs:

  • Breakpoint and step debugging β€” Limited to basic XSLT structures (templates, loops, expressions). Deep or dynamic template calls are intentionally not instrumented.
  • Variable inspection β€” Covers @select-based variables; content-defined variables are skipped for now.
  • Trace logging overhead β€” Minor runtime impact (~15% in traceall mode).
  • Platform-specific builds β€” Separate downloads for Windows x64 and macOS ARM.

These tradeoffs ensure reliable debugging without overcomplicating the runtime.

🧩 Note: This is a complementary developer tool for debugging and learning β€” not a production-grade runtime.


πŸ‘‰ VS Code Marketplace Windows x64
πŸ‘‰ VS Code Marketplace MacOS ARM

Built with ❀️ to make XSLT development less mysterious and more productive.

Top comments (1)

Collapse
 
roshan_sharma_7deae5e0742 profile image
roshan sharma

This is really impressive! Making XSLT debugging approachable in VS Code is a game-changer, especially for people dealing with legacy XML workflows. I like that you highlighted both the capabilities and the current limitations clearly.