Created
May 2, 2018 09:09
-
-
Save NarHakobyan/8a5a8b6c4d6f9ebc82f332516c78b084 to your computer and use it in GitHub Desktop.
Angular 5 tslint prettier best practice
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
| { | |
| "extends": [ | |
| "tslint:latest", | |
| "tslint-eslint-rules", | |
| "tslint-config-prettier" | |
| ], | |
| "rulesDirectory": [ | |
| "node_modules/codelyzer", | |
| "node_modules/tslint-origin-ordered-imports-rule/dist", | |
| "node_modules/tslint-consistent-codestyle/rules", | |
| "node_modules/tslint-rxjs-subject-restrictions-rule/dist", | |
| "tslint-plugin-prettier" | |
| ], | |
| "rules": { | |
| "prettier": [true, { "singleQuote": true, "tabWidth": 4, "printWidth": 115 }], | |
| "no-console": true, | |
| "no-submodule-imports": false, | |
| "rx-subject-restrictions": true, | |
| "no-unused": true, | |
| "no-return-undefined": true, | |
| "no-unnecessary-else": true, | |
| "no-collapsible-if": true, | |
| "no-as-type-assertion": true, | |
| "arrow-return-shorthand": true, | |
| "callable-types": true, | |
| "class-name": true, | |
| "no-multi-spaces": true, | |
| "prefer-for-of": true, | |
| "comment-format": [ | |
| true, | |
| "check-space" | |
| ], | |
| "curly": true, | |
| "deprecation": { | |
| "severity": "warn" | |
| }, | |
| "eofline": true, | |
| "forin": true, | |
| "import-blacklist": [ | |
| true, | |
| "rxjs", | |
| "rxjs/Rx" | |
| ], | |
| "import-spacing": true, | |
| "import-destructuring-spacing": true, | |
| "indent": [ | |
| true, | |
| "spaces", | |
| 4 | |
| ], | |
| "interface-over-type-literal": true, | |
| "interface-name": false, | |
| "label-position": true, | |
| "ordered-imports": false, | |
| "origin-ordered-imports": true, | |
| "max-line-length": [ | |
| true, | |
| 140 | |
| ], | |
| "member-access": false, | |
| "member-ordering": [ | |
| true, | |
| { | |
| "order": [ | |
| "public-static-field", | |
| "public-instance-field", | |
| "protected-instance-field", | |
| "protected-static-field", | |
| "private-instance-field", | |
| "private-static-field", | |
| "public-constructor", | |
| "public-static-method", | |
| "public-instance-method", | |
| "protected-static-method", | |
| "protected-instance-method", | |
| "private-static-method", | |
| "private-instance-method" | |
| ] | |
| } | |
| ], | |
| "no-arg": true, | |
| "no-bitwise": true, | |
| "no-consecutive-blank-lines": true, | |
| "no-console": [ | |
| true, | |
| "log", | |
| "debug", | |
| "time", | |
| "timeEnd", | |
| "trace" | |
| ], | |
| "no-construct": true, | |
| "no-debugger": true, | |
| "no-duplicate-super": true, | |
| "no-empty": false, | |
| "no-empty-interface": true, | |
| "no-eval": true, | |
| "no-inferrable-types": [ | |
| true, | |
| "ignore-params" | |
| ], | |
| "no-misused-new": true, | |
| "no-non-null-assertion": true, | |
| "no-shadowed-variable": true, | |
| "no-string-literal": false, | |
| "no-string-throw": true, | |
| "no-switch-case-fall-through": true, | |
| "switch-default": true, | |
| "no-trailing-whitespace": false, | |
| "no-unnecessary-initializer": true, | |
| "no-unused-expression": true, | |
| "no-unused-variable": true, | |
| "no-use-before-declare": true, | |
| "no-var-keyword": true, | |
| "object-literal-sort-keys": false, | |
| "one-line": [ | |
| true, | |
| "check-open-brace", | |
| "check-catch", | |
| "check-else", | |
| "check-whitespace" | |
| ], | |
| "prefer-const": true, | |
| "quotemark": [ | |
| true, | |
| "single" | |
| ], | |
| "radix": true, | |
| "semicolon": [ | |
| true, | |
| "always" | |
| ], | |
| "triple-equals": [ | |
| true, | |
| "allow-null-check" | |
| ], | |
| "typedef-whitespace": [ | |
| true, | |
| { | |
| "call-signature": "nospace", | |
| "index-signature": "nospace", | |
| "parameter": "nospace", | |
| "property-declaration": "nospace", | |
| "variable-declaration": "nospace" | |
| } | |
| ], | |
| "typeof-compare": true, | |
| "unified-signatures": true, | |
| "variable-name": false, | |
| "whitespace": [ | |
| true, | |
| "check-branch", | |
| "check-decl", | |
| "check-operator", | |
| "check-separator", | |
| "check-type", | |
| "check-module" | |
| ], | |
| "directive-selector": [ | |
| true, | |
| "attribute", | |
| "sk", | |
| "camelCase" | |
| ], | |
| "component-selector": [ | |
| true, | |
| "element", | |
| "sk", | |
| "kebab-case" | |
| ], | |
| "no-output-on-prefix": true, | |
| "use-input-property-decorator": true, | |
| "use-output-property-decorator": true, | |
| "use-host-property-decorator": true, | |
| "no-input-rename": true, | |
| "no-output-rename": true, | |
| "use-life-cycle-interface": true, | |
| "use-pipe-transform-interface": true, | |
| "component-class-suffix": true, | |
| "directive-class-suffix": true, | |
| "angular-whitespace": [ | |
| true, | |
| "check-interpolation" | |
| ], | |
| "banana-in-box": true, | |
| "templates-no-negated-async": true, | |
| "no-attribute-parameter-decorator": true, | |
| "no-forward-ref": true, | |
| "object-curly-spacing": [ | |
| true, | |
| "always" | |
| ], | |
| "pipe-naming": [ | |
| true, | |
| "camelCase" | |
| ] | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment