misskey-dev / misskey.js

Misskey SDK for JavaScript
MIT License
74 stars 25 forks source link

modify type definition of notifications/read according to the implementation #59

Open yuchiki opened 1 year ago

yuchiki commented 1 year ago

fix #60

What

The titile says:

Why

notifications/read's parameter was changed from an ID to a list of IDs.

https://github.com/misskey-dev/misskey/blob/42833cd9219cb8f5abd1756aa1c57b024b125710/packages/backend/src/core/NotificationService.ts#L27

But the type definition does not follow the change. This type is used in packages/sw/, but this package is not typechecked in CI now https://github.com/misskey-dev/misskey/blob/develop/packages/sw/src/scripts/notification-read.ts#L42

Additional info (optional)

N/A

yuchiki commented 1 year ago

https://github.com/misskey-dev/misskey/pull/10331 の中で、 node_modules/misskey-js/built/api.types.d.ts を直接↑の内容に書き換えた状態で , sw ディレクトリの中で npm run lint が走ることを確かめました!

@syuilo @saschanaz