-
Notifications
You must be signed in to change notification settings - Fork 226
Enable no-explicit-any throughout production code #3353
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
55c8601
e3a6678
a4294e2
334dbf5
ac707ff
ed96cbb
93e6c53
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,6 +9,7 @@ import { useCallback, useInsertionEffect, useRef } from "react"; | |
| * | ||
| * @param callback The callback to call when the event is triggered. | ||
| */ | ||
| // eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We could rewrite this function to avoid |
||
| export function useEffectEvent<T extends (...args: any[]) => any>(callback: T) { | ||
| const ref = useRef<T>(callback); | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -173,7 +173,7 @@ export function ResultsApp() { | |
| }, | ||
| selectedTable: tableName, | ||
| }, | ||
| origResultsPaths: undefined as any, // FIXME: Not used for interpreted, refactor so this is not needed | ||
| origResultsPaths: undefined as unknown as ResultsPaths, // FIXME: Not used for interpreted, refactor so this is not needed | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This whole situation in |
||
| sortedResultsMap: new Map(), // FIXME: Not used for interpreted, refactor so this is not needed | ||
| database: msg.database, | ||
| interpretation: msg.interpretation, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I couldn't find a good way around this so ended up just ignoring the eslint error. Admittedly I didn't try super hard, but I didn't want to end up with a solution that was unnecessarily complex either.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that this is the best solution, this is the same error that I ran into yesterday on the
CachedOperation, where seemingly...args: unknown[]isn't well supported.