fix(ci): use knip instead of depcheck

This commit is contained in:
Lukasz Mierzwa
2026-03-23 10:52:04 +00:00
committed by Łukasz Mierzwa
parent 4246c6e85f
commit dcec2cc457
18 changed files with 899 additions and 153 deletions

View File

@@ -25,4 +25,4 @@ const hashString = (s: string): number =>
const hashObject = (o: { [key: string]: any }): number =>
hashString(JSON.stringify(o, normalize(), 2));
export { normalize, hashString, hashObject };
export { hashObject };

View File

@@ -50,4 +50,3 @@ function localStored<T extends object>(
}
export { localStored };
export type { LocalStoreResult };

View File

@@ -266,4 +266,4 @@ const Fetcher: FC<{
);
});
export { Fetcher, Dots, PlayButton, PauseButton };
export { Fetcher, Dots };

View File

@@ -31,4 +31,4 @@ const GetGridElementWidth = (
(innerWidth - outerPadding) / GetColumnsCount(outerWidth, baseWidth),
);
export { GridSizesConfig, GetColumnsCount, GetGridElementWidth };
export { GridSizesConfig, GetGridElementWidth };

View File

@@ -10,7 +10,7 @@ import type { AlertStore } from "Stores/AlertStore";
const isBackgroundDark = (brightness: number) => brightness <= 130;
export interface ClassAndStyleT {
interface ClassAndStyleT {
style: { [key: string]: string | number };
className: string;
baseClassNames: string[];

View File

@@ -207,4 +207,4 @@ const DeleteSilence: FC<{
);
};
export { DeleteSilence, DeleteSilenceModalContent, DeleteResult };
export { DeleteSilence, DeleteSilenceModalContent };

View File

@@ -132,4 +132,4 @@ const SilenceComment: FC<{
},
);
export { SilenceComment, SilenceProgress };
export { SilenceComment };

View File

@@ -194,7 +194,7 @@ const SilenceDeleteModalContent: FC<{
);
};
export const MassDeleteProgress: FC<{
const MassDeleteProgress: FC<{
alertStore: AlertStore;
silences: ClusterSilenceT[];
}> = observer(({ alertStore, silences }) => {

View File

@@ -14,7 +14,7 @@ export type FetchFunctionT = (
init?: RequestInit | undefined,
) => Promise<Response>;
export interface FetchAnyOptionsT {
interface FetchAnyOptionsT {
fetcher?: null | FetchFunctionT;
}

View File

@@ -4,9 +4,9 @@ import merge from "lodash.merge";
import { CommonOptions } from "Common/Fetch";
export type useFetchDeleteDepsT = string[] | number[];
type useFetchDeleteDepsT = string[] | number[];
export interface ResponseStateT {
interface ResponseStateT {
response: null | string;
error: null | string;
isDeleting: boolean;

View File

@@ -81,7 +81,7 @@ export const EscapeRegex = (v: string): string => {
return v.replace(/[-/\\^$*+?.()|[\]{}]/g, "\\$&");
};
export const UnescapeRegex = (v: string): string => {
const UnescapeRegex = (v: string): string => {
return v.replaceAll("\\", "");
};
@@ -270,8 +270,8 @@ const UnpackRegexMatcherValues = (isRegex: boolean, value: string) => {
}
};
export type SilenceFormTabT = "editor" | "browser";
export type SilenceFormStageT = "form" | "preview" | "submit";
type SilenceFormTabT = "editor" | "browser";
type SilenceFormStageT = "form" | "preview" | "submit";
interface SilenceFormStoreToggleT {
visible: boolean;
@@ -709,7 +709,6 @@ export {
NewEmptyMatcher,
AlertmanagerClustersToOption,
MatchersFromGroup,
MatchersFromAlerts,
GenerateAlertmanagerSilenceData,
NewClusterRequest,
MatcherToOperator,

View File

@@ -1,5 +1,3 @@
/// <reference types="react-scripts" />
declare module "react-media-hook" {
function useMediaPredicate(query: string): boolean;
}