-
Type:
Suggestion
-
Resolution: Unresolved
-
None
-
Component/s: Pull Request - Comments
-
None
If I want to add a comment about a code block, it makes zero sense for the comment to lob up right in the middle of the code block being commented on.
Current (silly) way
var a = b + c
Comment: Why can't all of this be done in a single line statement.
var d = a + e + f
var g = d + h + i
Best way
Comment: Why can't all of this be done in a single line statement.
var a = b + c
var d = a + e + f
var g = d + h + i
I always add my comment to the line above so I don't destroy readability, but someone has just pointed out to me that my comments are visually linked to the incorrect line.