Closed BaptisteHubert closed 2 years ago
@BaptisteHubert could you update me on what is left, via the addition of todo boxes in the PR body?
arrow-body-style
- warn - Not a problem in the code right now. Definitely will be addressed in the update where we will get rid of the remaining warnings.no-underscore-dangle
- warn - Not a problem in the code right now, since private variable needs to be used. Though, the number of warning associated being large enough, the way it is handled in the code is subject to change in the next update.@typescript-eslint/member-ordering
- warn - Not a problem right now in the code. It is still listed as warn to fix it in the next update.@typescript-eslint/naming-convention
- warn - Not a real problem too. We will try and fix most of it in the next update.jsdoc/newline-after-description
- off - Spaces between description and functions are already visible when we use extensions such as gitlens. Furthermore, personal preference to keep it that way@angular-eslint/component-selector
- warn - Still to be discussed about, but adding app to the component selector seems to not be useful in our application. Furthermore, most of the components selector already starts with mute.prefer-arrow/prefer-arrow-functions
- warn - personal preferences ATM, ancient function not in arrow-style will be addressed in the next update.@angular-eslint/directive-selector
- warn - Like the component selector, this rule can be discussed about. Directives selector already have mute as prefix. In the next update, it might even be toggled as "off"@angular-eslint/contextual-lifecycle
- warn - Tested in the cursors.directive.ts, the ngOnInit is called.These modifications were made following a run of eslint in --quiet
mode, only showing errors
typing.d.ts
-> disabled the no-var
rule in the filebot-storage.service.ts
- > corrected file according to the curly
rule (Expected { after 'if' condition)File.ts
-> disabled the @typescript-eslint/unified-signatures
on the two specific line where it was a problem. The set function has the same name as the get function for title
and description
(abstract get and abstract set). Seeing the code (and knowing file is used a lot), changing it will be done in a new updatelocal-storage.service.ts
-> disabled @typescript-eslint/no-unused-expressions
because an expression with === and ? and : is used. This should be addressed in the next update.details.component.ts
-> Added breaks in the switch in ngOnInit() relatively to the no-fallthrough
rulecontrols.component.ts
-> Modified the constructor, which contained an expression. The class is never called.collaborators.component.ts
-> Modified the EventEmitter's name relatively to @angular-eslint/no-output-native
pulsar.service.ts
-> Modified the way msgIdFromStorage
was declared relatively to the prefer-const
rulemock-authors.ts
-> Modified the ways the AUTHORS const is defined. Following the @typescript-eslint/array-type
, Array type using Array<T>
is forbidden. Use T[]
instead. avatar.component.ts
-> Added implements OnInit to follow the @angular-eslint/use-lifecycle-interface
. The update was done following this (source)doc.po.ts
-> modified the fact that we used Promise<{}>
because {}
actually means any non-nullish value
. Instead, we use Promise<unknown>
protractor.conf.js
& update-app-data.js
-> Added /*eslint-env es6*/
on top of the file to remove the parsing error : The keyword 'const' is reserved
Please check if the PR fulfills these requirements
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) This PR introduces the changes needed for the project to use ESLint instead of TSLint (which has been deprecated in 2020 by Angular)
TO-DO Boxes