Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

getAccessToken 에러 #8

Closed
akyeongah opened this issue Sep 17, 2021 · 4 comments
Closed

getAccessToken 에러 #8

akyeongah opened this issue Sep 17, 2021 · 4 comments

Comments

@akyeongah
Copy link

akyeongah commented Sep 17, 2021

리액트 네이티브 환경에서 getAccessToken를 사용한 경우 에러가 발생합니다.

에러 메시지입니다.
[TypeError: str.replace is not a function. (In 'str.replace(' ', 'T')', 'str.replace' is undefined)]

구현 코드입니다.
`export async function getAccessToken () {

KakaoSDK.getAccessToken()

    .then((res) => {
        console.log('getAccessToken res: ', res)
    })

    .catch((err) => {
        console.log('getAccessToken err: ', err)
    })

}`

getAccessToken가 아닌 login, getProfile은 정상작동하는 상황입니다.

@ChanghyeonYoon
Copy link
Contributor

ChanghyeonYoon commented Sep 22, 2021

@akyeongah
KakaoSDK v2부터는 getAccessToken을 지원하지 않습니다.
login에서 리턴되는 토큰으로 사용 부탁드립니다.

해당 내용 리드미 수정하겠습니다.

@ChanghyeonYoon
Copy link
Contributor

Duplicate of #5

suhanmoon added a commit that referenced this issue Sep 27, 2021
@akyeongah
Copy link
Author

그럼 로그인 없이 Access토큰을 재발급할 수 있는 방법은 없는 것인가요?

@akyeongah akyeongah reopened this Sep 29, 2021
@ChanghyeonYoon
Copy link
Contributor

@akyeongah 네. 로그인 성공 시 필요한 정보들을 디바이스에 저장해서 사용 부탁드립니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants