-
Notifications
You must be signed in to change notification settings - Fork 12
Closed
Description
I don't like config formats which don't support comments, and although tslint supports comments in the configuration file tslint.json, it's not strictly JSON and so github highlights comments in all red. So I'd like to use another option.
Option 1, JavaScript: tslint.js:
module.exports = {
"defaultSeverity": "error",
"extends": [
"tslint:recommended"
],
"jsRules": {},
"rules": {
"no-any": true,
// TODO perhaps we *should* use the 'I' prefix?
"interface-name": [true, "never-prefix"],
"no-unused-expression": [true, "allow-fast-null-checks"]
},
"rulesDirectory": []
}Or option 2, YAML: tslint.yaml:
defaultSeverity: error
extends:
- 'tslint:recommended'
jsRules:
rules:
no-any: true
# TODO perhaps we *should* use the 'I' prefix?
interface-name: [true, never-prefix]
no-unused-expression: [true, allow-fast-null-checks]
rulesDirectory: []
I prefer option 2, but I know YAML can be a bit of an adjustment, so let me know what you think, @BANG88 .
EDIT: yaml uses # for comments, not //
Metadata
Metadata
Assignees
Labels
No labels