klarna / electron-redux

Use redux in the main and browser processes in electron
MIT License
743 stars 94 forks source link

chore: add eslint #268

Closed matmalkowski closed 3 years ago

matmalkowski commented 3 years ago

This PR adds eslint setup to the reposiory. It doesn't fix existing errors/warnings - should get addressed in follow up Pull Requests since the codebase isn't final now anyway. Errors so far:

klarna/electron-redux/src/syncRenderer.ts
   85:27  warning  Unexpected any. Specify a different type  @typescript-eslint/no-explicit-any
  105:32  warning  Unexpected any. Specify a different type  @typescript-eslint/no-explicit-any

klarna/electron-redux/src/utils/actions.ts
  15:31  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types

klarna/electron-redux/src/utils/json.ts
  22:24  warning  Missing return type on function                       @typescript-eslint/explicit-module-boundary-types
  22:36  warning  Argument 'value' should be typed with a non-any type  @typescript-eslint/explicit-module-boundary-types
  22:43  warning  Unexpected any. Specify a different type              @typescript-eslint/no-explicit-any

klarna/electron-redux/src/utils/misc.ts
   7:44  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types
  24:29  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types
  33:31  warning  Missing return type on function  @typescript-eslint/explicit-module-boundary-types

klarna/electron-redux/tests/e2e/renderer/index.ts
   9:5  warning  Forbidden non-null assertion  @typescript-eslint/no-non-null-assertion
  18:5  warning  Forbidden non-null assertion  @typescript-eslint/no-non-null-assertion
  22:5  warning  Forbidden non-null assertion  @typescript-eslint/no-non-null-assertion
  32:5  warning  Forbidden non-null assertion  @typescript-eslint/no-non-null-assertion

klarna/electron-redux/tests/typescript/syncMain.ts
  5:7  warning  'store' is assigned a value but never used  @typescript-eslint/no-unused-vars

klarna/electron-redux/tests/typescript/syncRenderer.ts
  5:7  warning  'store' is assigned a value but never used  @typescript-eslint/no-unused-vars

✖ 15 problems (0 errors, 15 warnings)
matmalkowski commented 3 years ago

:tada: This PR is included in version 2.0.0-alpha.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket: