Tslint: Why is "I" prefix interface-name default?

Created on 3 Oct 2018  路  4Comments  路  Source: palantir/tslint

I'm not sure if a "feature request" is the proper ticket type to raise this issue on Github. Nonetheless, I would like to know why the default for the interface-name rule is to prefix with "I". The rationale given is _Makes it easy to differentiate interfaces from regular classes at a glance_ which I'm not arguing with. The main reason I disagree with the default for this rule is that the coding guidelines for _contributors to Typescript` - which you could easily say should be the template for all Typescript coding standards - say not to use "I" as a prefix for interface names. Additionally, I rarely see libraries, coding examples, etc. that use the "I" prefix.

Our team would like to use all the TSLint defaults, but we're having a hard time with this one...

Duplicate

Most helpful comment

I double checked, I was wrong, sorry.

All 4 comments

I also find some of tslint:recommended rules make no sense, like "trailing-comma": true for instance (it changes the way the code behave, both in TS and JS). For that reason, I use other configurations, such as tslint-config-standard

Duplicate of #1520.

@KSXGitHub how does trailing comma change code behavior?

I double checked, I was wrong, sorry.

Was this page helpful?
0 / 5 - 0 ratings