opencast / opencast-admin-interface

A modern admin user interface for Opencast
https://admin-interface.opencast.org
Educational Community License v2.0
1 stars 22 forks source link

Get rid of linter and type-checker exceptions #469

Open JulianKniephoff opened 1 month ago

JulianKniephoff commented 1 month ago

There should be no eslint-ignore-next-line or @ts-expect-error comments and the like in the code anywhere.

Maybe that's idealistic, but right now we have too many, some of which definitely hide some bugs (which are unfortunately not always easily fixed). Others suggest that we might want to talk about whether or not we want to enforce certain rules.

One way or the other, in the end, there should be a minimal set of these comments, preferably the empty set, each justifying their existence with some additional comments.

Arnei commented 1 month ago

Partial duplicate of #208

Arnei commented 1 month ago

Also we arguably do not want to remove all eslint-ignore-next-line, as they are sometimes required to achieve certain uses cases (e.g. often the case with useEffect dependencies).

JulianKniephoff commented 1 month ago

Arguably yes, as in we can argue about it, but specifically the uses I found around useEffect all indicated wrong usages of/assumptions about how useEffect works. 🤷‍♀️ I haven't seen everything, of course, but sure, if we really need such a comment in places I would say it needs an explanation.