hmil / tslint-override

TSLint plugin bringing support for the override keyword
MIT License
27 stars 6 forks source link

Add support for changing the casing of the decorator for use in the fixer #14

Closed ChiriVulpes closed 5 years ago

ChiriVulpes commented 5 years ago

The rest of the decorators we use in my project are capitalised. It's nice that this tslint rule still allows those to pass, but it'd be nicer if the fixer had a way to work with that style as well.

Maybe support passing a string option that must start with @, and that is the name of the decorator? IE:

"explicit-override": [true, "decorator", "exclude-interfaces", "@Override"],

But I guess then someone could change it to something meaningless like @Foo, maybe you wouldn't want to do it that way for that reason

ChiriVulpes commented 5 years ago

Implemented in https://github.com/Yuudaari/tslint-override

I can make a PR later if you like, if this way about going about it looks ok to you (I assume I should add tests too)

hmil commented 5 years ago

Sure, that sounds like a reasonable feature. Feel free to open a PR with the work you've done.

hmil commented 5 years ago

I did a bunch of changes to fix your other issue #15 . You might want to rebase your change on top of master.