fjs21/homebridge-blueair

Lint issue again

Closed this issue · 2 comments

fjs21 commented
/home/pi/dev/homebridge-blueair/src/blueair-aws-api.ts
   26:29  error    Don't use `object` as a type. The `object` type is currently hard to use ([see this issue](https://github.com/microsoft/TypeScript/issues/21732)).
Consider using `Record<string, unknown>` instead, as it allows you to more easily inspect and use the keys  @typescript-eslint/ban-types

Hi @jonato1, I tried to publish v1.1.1 with some minor fixes but ran into this issue again. I did some googling and it appears the use of object as a type is frowned upon.

Would this work?

private readonly awsKeys: Record<string, unknown>;

Hi @fjs21 - I think my latest commit should fix this (hopefully once and for all). 1b93208

Let me know if it passes the lint on your end - it looks like it passed the automated checks in GitHub for the npm publish --dry-run.

Thanks,
Jon

fjs21 commented

Looks good. Thanks.