millo-L / react-native-kakao-share-link

리액트 네이티브 카카오 링크 오픈 소스
MIT License
30 stars 24 forks source link

Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want? #9

Open GeunwonChoi opened 2 years ago

GeunwonChoi commented 2 years ago
image

해당 라이브러리를 사용하시는 사용자분들 중에 해당 오류가 발생하는 분이 계실까요?

guswls1846 commented 2 years ago

안드로이드 경우 KakaoShareLinkModule.kt 코드를 보면 카카오톡 설치가 안된 상태에서 sendWithTemplate 호출하면 예외처리로 KakaoCustomTabsClient로 브라우저를 열게끔 작성되어있는데 KakaoCustomTabsClient에서 mainActivity가 중복 호출 되서 발생되는거 같습니다.

저는 급한대로 해당 예외처리를 지우고 카카오톡이 설치가 안된 상태면 promise.reject("E_KAKAO_NO_INSTALL, "E_KAKAO_NO_INSTALL") 처럼 바로 reject 날리고 react 코드에서 try/catch 문으로 해당 리젝트가 발생하면 바로 플레이스토어 카카오톡 설치 페이지로 넘겼습니다.

GeunwonChoi commented 2 years ago

KakaoCustomTabsClient

답변 감사합니다!

GeunwonChoi commented 2 years ago

ise.rej

혹시 뚜렷한 해결 방법은 없는것일까요? 조심스레 여쭈어봅니다!

2sem commented 1 year ago

https://github.com/millo-L/react-native-kakao-share-link/issues/17

2sem commented 1 year ago

RNKakaoLink는 카카오 홈피로 보내는데 카카오에서 라이브러리 고치기 전에는 스토어로 보내게 하는 수 밖에 없는걸까여 ㅠㅠ

2sem commented 1 year ago

https://devtalk.kakao.com/t/topic/22823/4 오래된 문제인것 같군요...