clutchski / coffeelint

Lint your CoffeeScript.
http://www.coffeelint.org
Other
1.17k stars 172 forks source link

A rule that TODOs should be uniformly formatted #434

Open mitar opened 9 years ago

mitar commented 9 years ago

Feature request.

Good:

# TODO: This has to be done.

Bad:

# TODO This has to be done.
# TODO : This has to be done.

Just to make it easier for some IDEs to parse this.

AsaAyers commented 9 years ago

I often look to how eslint names things. They have a no-warning-comments rule. I'd probably name this warning_comments and give it one configuration parameter.

module.exports = class WarningComments
    rule:
        name: 'warning_comments'
        level: 'warn'
        mode: 'format' # Or set this to 'forbid' if you want to ban warning comments.
        message: 'Curly braces must have the proper spacing'