diff --git a/src/app/api/auth/verify-otp/route.ts b/src/app/api/auth/verify-otp/route.ts index 0d741fd..feb311e 100644 --- a/src/app/api/auth/verify-otp/route.ts +++ b/src/app/api/auth/verify-otp/route.ts @@ -7,10 +7,7 @@ import { auth } from "@/auth"; import { eq } from "drizzle-orm"; // In-memory store for rate limiting -const rateLimit = new Map< - string, - { requests: number; lastRequestTime: number } ->(); +const rateLimit = new Map < string, { requests: number; lastRequestTime: number } >(); // Rate limiting configuration const MAX_REQUESTS = 3; // Max requests per window diff --git a/src/components/Screen.tsx b/src/components/Screen.tsx index 2b83a88..e192a0d 100644 --- a/src/components/Screen.tsx +++ b/src/components/Screen.tsx @@ -1,29 +1,29 @@ -"use client"; - -import { useState, useEffect } from 'react'; - -const ScreenWidth: React.FC = () => { - const [screenWidth, setScreenWidth] = useState(0); - - useEffect(() => { - // Function to update the screen width - const updateWidth = () => setScreenWidth(window.innerWidth); - - // Set the initial width - updateWidth(); - - // Add event listener to track window resize - window.addEventListener('resize', updateWidth); - - // Cleanup event listener on component unmount - return () => window.removeEventListener('resize', updateWidth); - }, []); - - return ( -
-

Screen Width: {screenWidth}px

-
- ); -}; - -export default ScreenWidth; +// "use client"; +// +// import { useState, useEffect } from 'react'; +// +// const ScreenWidth: React.FC = () => { +// const [screenWidth, setScreenWidth] = useState(0); +// +// useEffect(() => { +// // Function to update the screen width +// const updateWidth = () => setScreenWidth(window.innerWidth); +// +// // Set the initial width +// updateWidth(); +// +// // Add event listener to track window resize +// window.addEventListener('resize', updateWidth); +// +// // Cleanup event listener on component unmount +// return () => window.removeEventListener('resize', updateWidth); +// }, []); +// +// return ( +//
+//

Screen Width: {screenWidth}px

+//
+// ); +// }; +// +// export default ScreenWidth;