jcberquist / commandbox-cfformat

A CommandBox module for formatting CFML component files.
MIT License
22 stars 10 forks source link

Suggestion: Add more context for "Unbalanced closing tag found" errors #102

Closed gls7 closed 3 years ago

gls7 commented 3 years ago

We have a cfc that builds emails based on many conditions. We create both text and html versions of the messages. In this situation we may have starting and ending tags in different code blocks so we'll need to ignore those parts. The problem is finding them as the current error message doesn't give line numbers or larger context of the line or other information to find the problem.

jcberquist commented 3 years ago

Unfortunately, given the way the formatting currently works, accessing the line numbers for these errors is tricky. I built a separate command into cfformat to try and help with these situations. Could you try using the command cfformat tag-check on the files causing the errors?

gls7 commented 3 years ago

That's perfect! I got through the mess of tags and it's all good now. Thanks!