chore: enable linting ts files (#6351)

* chore: initial setup for linting ts

* chore: Temporarily disable most of the rules causing problems

* chore: fix autofixable problems.

* chore: ignore the last few files and rules

* chore: fix remaining lint errors

* chore: fix more small lint

* chore: run original rules on js files, new ts rules on ts files

* chore: use jsdoc style return in js files

* chore: add lint fix script

* chore: fix prefer-spread lint

* chore: fix no-invalid-this rule

* chore: fix no-unused-vars

* chore: fix trashcan lint
This commit is contained in:
Maribeth Bottorff
2022-08-16 13:59:15 -07:00
committed by GitHub
parent 9830641cb7
commit 49f87fba79
48 changed files with 560 additions and 79 deletions

View File

@@ -298,7 +298,7 @@ export class VariableMap {
* @return The variable with the given ID.
*/
getVariableById(id: string): VariableModel|null {
for (const [key, variables] of this.variableMap) {
for (const [_key, variables] of this.variableMap) {
for (const variable of variables) {
if (variable.getId() === id) {
return variable;
@@ -365,7 +365,7 @@ export class VariableMap {
getAllVariableNames(): string[] {
return Array.from(this.variableMap.values())
.flat()
.map(variable => variable.name);
.map((variable) => variable.name);
}
/**