isKakaoNaviInstalled method

Future<bool> isKakaoNaviInstalled()

KO: 카카오내비 앱 실행 가능 여부 확인
EN: Check whether the Kakao Navi app is available

Implementation

Future<bool> isKakaoNaviInstalled() async {
  Map<String, String> arguments = {};
  if (kIsWeb) {
  } else if (_platform.isAndroid) {
    arguments.addAll(
        {Constants.naviOrigin: KakaoSdk.platforms.android.kakaoNaviOrigin});
  } else {
    arguments.addAll(
        {Constants.naviOrigin: KakaoSdk.platforms.ios.kakaoNaviScheme});
  }

  final isInstalled = await _channel.invokeMethod<bool>(
          CommonConstants.isKakaoNaviInstalled, arguments) ??
      false;
  return isInstalled;
}