Files
zitadel/apps/login/app/(login)/error.tsx
2023-04-27 13:23:13 +02:00

25 lines
629 B
TypeScript

"use client";
import { Boundary } from "#/ui/Boundary";
import { Button } from "#/ui/Button";
import React from "react";
export default function Error({ error, reset }: any) {
React.useEffect(() => {
console.log("logging error:", error);
}, [error]);
return (
<Boundary labels={["Home page Error UI"]} color="pink">
<div className="space-y-4">
<div className="text-sm text-pink-500">
<strong className="font-bold">Error:</strong> {error?.message}
</div>
<div>
<Button onClick={() => reset()}>Try Again</Button>
</div>
</div>
</Boundary>
);
}