ci: enable depcheck and fix dependency and linter issues (#233)

* ci: enable depcheck and fix dependency and linter issues

* chore: lock dependency versions

* chore: update dependencies to latest working ones

* chore: fix deprecation createMuiTheme

* chore: revert notistack to v1
This commit is contained in:
Vojtech Simetka
2021-11-08 13:33:12 +01:00
committed by GitHub
parent 15b4b0e561
commit 7883d053ed
14 changed files with 10499 additions and 5424 deletions
+4 -4
View File
@@ -153,7 +153,7 @@ export function Provider({ children }: Props): ReactElement {
setApiHealth(false)
refresh()
}, [beeApi])
}, [beeApi]) // eslint-disable-line react-hooks/exhaustive-deps
useEffect(() => {
setIsLoading(true)
@@ -169,7 +169,7 @@ export function Provider({ children }: Props): ReactElement {
setSettlements(null)
refresh()
}, [beeDebugApi])
}, [beeDebugApi]) // eslint-disable-line react-hooks/exhaustive-deps
const refresh = async () => {
// Don't want to refresh when already refreshing
@@ -279,7 +279,7 @@ export function Provider({ children }: Props): ReactElement {
await Promise.allSettled(promises)
} catch (e) {
setError(e)
setError(e as Error)
} finally {
setIsLoading(false)
setIsRefreshing(false)
@@ -300,7 +300,7 @@ export function Provider({ children }: Props): ReactElement {
return () => clearInterval(interval)
}
}, [frequency, beeDebugApi, beeApi])
}, [frequency, beeDebugApi, beeApi]) // eslint-disable-line react-hooks/exhaustive-deps
return (
<Context.Provider
+2 -2
View File
@@ -68,7 +68,7 @@ export function Provider({ children }: Props): ReactElement {
setStamps(stamps.map(enrichStamp))
setLastUpdate(Date.now())
} catch (e) {
setError(e)
setError(e as Error)
} finally {
setIsLoading(false)
}
@@ -87,7 +87,7 @@ export function Provider({ children }: Props): ReactElement {
return () => clearInterval(interval)
}
}, [frequency])
}, [frequency]) // eslint-disable-line react-hooks/exhaustive-deps
return (
<Context.Provider value={{ stamps, error, isLoading, lastUpdate, start, stop, refresh }}>