diff --git a/src/App.tsx b/src/App.tsx
index d8822ef..cfc59c7 100644
--- a/src/App.tsx
+++ b/src/App.tsx
@@ -1,16 +1,22 @@
+import { useState } from "react";
+import Alert from "./components/Alert";
import { Button } from "./components/Button";
-function handleOnClick() {
- console.log("Clicked");
-}
+
+// function handleOnClick() {
+// //console.log("Clicked");
+// }
function App() {
+ const [alertVisible, setAlertVisibility] = useState(false);
return (
-
+ {alertVisible &&
setAlertVisibility(false)}>Holly wacamole!}
+
+
);
}
diff --git a/src/components/Alert.tsx b/src/components/Alert.tsx
index 708970d..31c4b04 100644
--- a/src/components/Alert.tsx
+++ b/src/components/Alert.tsx
@@ -2,11 +2,14 @@ import type { ReactNode } from "react";
interface Props{
children: ReactNode;
+ onClose:()=>void;
}
-function Alert({children} : Props) {
+function Alert({children, onClose} : Props) {
return (
- {children}
+ {children}
+
+
)
}