mirror of
https://github.com/Alvin-Zilverstand/nginx-proxy-manager.git
synced 2026-11-21 13:52:59 +01:00
- Per-path access lists: assign different access lists to individual locations on the same proxy host - Host logs modal: view access/error logs from proxy host dropdown - PostgreSQL JSON containment query (@>) for location regeneration - Locale keys: action.logs, column.error
13 lines
374 B
TypeScript
13 lines
374 B
TypeScript
import { useQuery } from "@tanstack/react-query";
|
|
import { getProxyHostLogs } from "src/api/backend";
|
|
|
|
const useProxyHostLogs = (id: number, type: "access" | "error" = "access") => {
|
|
return useQuery<{ logs: string }, Error>({
|
|
queryKey: ["proxy-host-logs", id, type],
|
|
queryFn: () => getProxyHostLogs(id, type),
|
|
staleTime: 10_000,
|
|
});
|
|
};
|
|
|
|
export { useProxyHostLogs };
|