Files
kandev/apps/web/app/settings/general/notifications/page.tsx
T
2026-02-19 22:18:01 +00:00

28 lines
788 B
TypeScript

import { NotificationsSettings } from "@/components/settings/notifications-settings";
import { StateProvider } from "@/components/state-provider";
import { listNotificationProviders } from "@/lib/api";
export default async function GeneralNotificationsPage() {
let initialState = {};
try {
const response = await listNotificationProviders({ cache: "no-store" });
initialState = {
notificationProviders: {
items: response.providers ?? [],
events: response.events ?? [],
appriseAvailable: response.apprise_available ?? false,
loaded: true,
loading: false,
},
};
} catch {
initialState = {};
}
return (
<StateProvider initialState={initialState}>
<NotificationsSettings />
</StateProvider>
);
}