having whitespace on an empty line does not trigger the trailing-whitespace rule, even though leading whitespace might exist due to autoindenters... might be nice to have a separate rule for this corner case?
# next line contains trailing whitespace (really, though markdown strips it!)
was expecting it to trigger "Line 3 contains trailing whitespace"
I suppose if other linters check empty lines for trailing whitespace we should be consistent. This is the regex we currently use:
trailingWhitespace : /[^\s]+[\t ]+\r?$/
So, this was the original behaviour, but other folks didn't like that, so it was changed in #9. Maybe it's worth an option in the no_trailing_whitespace config?
I think it would be good to have.
i really agree
+1, I would like this as well
Fixes #39 Added an option to forbid trailing space on empty lines
Please add parameter 'allowed_in_empty_lines' to the documentation at http://www.coffeelint.org/