Skip to content

Commit

Permalink
Merge pull request #80 from DeveloperRyou/develop
Browse files Browse the repository at this point in the history
HOTFIX: KAKAO 로그인 버튼 동작하도록 수정
  • Loading branch information
DeveloperRyou authored May 19, 2024
2 parents abd88ea + e43b03e commit b67c4cb
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions src/assist/buttonwrapper/KakaoLoginButtonWrapper.tsx
Original file line number Diff line number Diff line change
@@ -1,23 +1,18 @@
import LoginButton from "@modules/components/button/LoginButton";
import FlexBox from "@modules/layout/FlexBox";
import { useEffect } from "react";

function KakaoLoginButtonWrapper() {
const kakaoSDKLogin = () => {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const kakao = (window as any).Kakao;
if (!kakao?.isInitialized()) {
kakao?.init(process.env.NEXT_PUBLIC_KAKAO_JS_KEY);
}
const redirectUri = `https://api.eolluga.com/login/oauth2/code/kakao`;
kakao?.Auth?.authorize({
redirectUri,
});
};
useEffect(() => {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const kakao = (window as any)?.Kakao;
if (!kakao?.isInitialized()) {
kakao?.init(process.env.NEXT_PUBLIC_KAKAO_JS_KEY);
}
}, []);
return (
<FlexBox className="px-4 w-full justify-center">
<div className="w-full max-w-[360px]">
Expand Down

0 comments on commit b67c4cb

Please sign in to comment.