Blog Post

Inspecting TSQL Abstract Syntax Trees

,

TSQL ScriptDOM is a useful library for parsing scripts into an abstract syntax tree. I've built a web tool that helps visualize this tree as a learning exercise.

Foreword

I've leveraged the ScriptDOM library in the past, for example, to build a homegrown linter. Or you can use the library to build your own formatter with the correct set of rules.

Try It Out

Head over to TSQL Visualizer and paste in some TSQL. My main goal was to build Editor, Tree and Fragment panels with a three-way sync: when you click somewhere, it highlights the position in the other two.

TSQL Visualizer Preview

About the Project

Full transparency: this tool is a vibe-coded, AI-assisted project. I'm learning C# and Blazor, and building something useful seemed like a better way to learn than following tutorials. The code is probably not production-grade, but it works and hopefully helps others understand ScriptDOM.

Thank you for reading

Original post (opens in new tab)

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating