__CAPGO_KEEP_0__ 4에서 __CAPGO_KEEP_1__ 5로 업데이트하는 방법: 단계별 안내
Capacitor

Capacitor 4에서 Capacitor 5로 업데이트하는 방법: 단계별 안내

Capacitor 4에서 Capacitor 5로 업데이트하여 최소한의 깨진 변경으로 프로젝트를 업데이트하는 방법을 알아보세요. 이 업데이트에는 공식 플러그인 및 필수 도구의 업데이트가 포함됩니다.

마틴 도나디유

마틴 도나디유

콘텐츠 마케터

Capacitor 4에서 Capacitor 5로 업데이트하는 방법: 단계별 안내

Capacitor 4에서 Capacitor 5로의 전환은 이전 업데이트와 비교하여 최소한의 깨진 변경 사항을 포함합니다. 이 안내서에서는 Capacitor 5로 프로젝트를 업데이트하는 단계별 지침을 제공하며, 공식 플러그인에 대한 깨진 변경 사항 목록도 제공합니다.

주의: Capacitor 5는 NodeJS 16 이상이 필요하며, Node 12은 종료되었으며 Node 14은 2023년 4월 30일 종료될 예정입니다. 최신 LTS 버전의 NodeJS를 사용하는 것을 권장합니다.

  1. __CAPGO_KEEP_0__ __CAPGO_KEEP_1__의 __CAPGO_KEEP_0__ 버전을 프로젝트에 설치하세요. latest version of the Capacitor CLI in your project:

    npm i -D @capacitor/cli@latest
  2. Run the following command to let the CLI handle the migration:

    npx cap migrate

    VS __CAPGO_KEEP_0__ 확장 프로그램이 설치되어 있다면, 확장 프로그램의 추천 섹션에서 프로젝트를 __CAPGO_KEEP_1__ 5로 마이그레이션하는 옵션을 찾으십시오.

  3. Code 4 iOS 프로젝트를 Capacitor 5로 업그레이드하세요.

Upgrading Capacitor 4 iOS Project to Capacitor 5

  1. : __CAPGO_KEEP_0__ 5는 Xcode 14.1 이상이 필요합니다.: Capacitor 5 requires Xcode 14.1+.

  2. __CAPGO_KEEP_0__ 5는 NodeJS 16 이상이 필요하며, Node 12은 종료되었으며 Node 14은 2023년 4월 30일 종료될 예정입니다. 최신 LTS 버전의 NodeJS를 사용하는 것을 권장합니다.: __CAPGO_KEEP_0__의 변경 사항을 적용하세요. .gitignore file:

    - App/Podfile.lock
    + App/output
  3. Update Assets를 사용하여 단일 앱 아이콘을 업데이트하세요.: Xcode 14은 1024x1024의 단일 앱 아이콘을 지원합니다. AppIcon.appiconset을 업데이트하여 불필요한 모든 크기를 제거하세요.

Upgrading Capacitor 4 Android Project를 Capacitor 5로 업그레이드하세요.

  1. Android Studio를 업그레이드하세요.: Capacitor 5는 Android Studio Flamingo | 2022.2.1 이상이 필요합니다. Gradle 8의 사용으로 인해 Java JDK 17이 필요합니다. Java 17은 Android Studio Flamingo와 함께 제공되므로 추가 다운로드가 필요하지 않습니다.

  2. AGP Upgrade Assistant를 실행하세요.: Android Studio는 Gradle과 빌드 파일에 패키지를 이동하는 업데이트와 관련된 일부 업데이트를 도와줄 수 있습니다. 시작하려면 Tools -> AGP Upgrade Assistant.

  3. Android Project 변수를 업데이트하세요.: __CAPGO_KEEP_0__에서 variables.gradle file을 열고, 다음 새로운 최소값으로 값을 업데이트하세요.

    minSdkVersion = 22
    compileSdkVersion = 33
    targetSdkVersion = 33
    androidxActivityVersion = '1.7.0'
    androidxAppCompatVersion = '1.6.1'
    androidxCoordinatorLayoutVersion = '1.2.0'
    androidxCoreVersion = '1.10.0'
    androidxFragmentVersion = '1.5.6'
    coreSplashScreenVersion = '1.0.0'
    androidxWebkitVersion = '1.6.1'
    junitVersion = '4.13.2'
    androidxJunitVersion = '1.1.5'
    androidxEspressoCoreVersion = '3.5.1'
    cordovaAndroidVersion = '10.1.1'
  4. Google 서비스 업데이트:

    # build.gradle
    dependencies {
    -       classpath 'com.google.gms:google-services:4.3.13'
    +       classpath 'com.google.gms:google-services:4.3.15'
    }
  5. Gradle 플러그인을 8.0.0으로 업데이트:

    # build.gradle
    dependencies {
    -       classpath 'com.android.tools.build:gradle:7.2.1'
    +       classpath 'com.android.tools.build:gradle:8.0.0'
    }
  6. Gradle wrapper를 8.0.2로 업데이트:

    # gradle-wrapper.properties
    distributionBase=GRADLE_USER_HOME
    distributionPath=wrapper/dists
    - distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip
    + distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-all.zip
    zipStoreBase=GRADLE_USER_HOME
    zipStorePath=wrapper/dists
  7. Jetifier를 비활성화:

    # gradle.properties
    android.useAndroidX=true
    - android.enableJetifier=true
  8. 패키지를 build.gradle:

    # AndroidManifest.xml
    <?xml version="1.0" encoding="utf-8"?>
    - <manifest xmlns:android="http://schemas.android.com/apk/res/android"
    -     package="[YOUR_PACKAGE_ID]">
    + <manifest xmlns:android="http://schemas.android.com/apk/res/android">
    # build.gradle
    android {
    +     namespace "[YOUR_PACKAGE_ID]"
          compileSdkVersion rootProject.ext.compileSdkVersion
  9. androidScheme을 업데이트: Capacitor 6에서 https __CAPGO_KEEP_0__를 사용하는 기존 앱을 위해 시스템 Autofill 기능을 사용할 수 있도록 하기 위해 androidScheme for existing apps to better enable Capacitor applications to use the system Autofill feature. To avoid data loss as a result of this change, set the scheme to http 현재 기본값이지만,

    {
      server: {
        androidScheme: "http"
      }
    }
  10. Kotlin 버전을 업데이트: 프로젝트가 Kotlin을 사용하는 경우, Kotlin 버전을 업데이트 kotlin_version 변수에 '1.8.20'.

플러그인 기능 변경

다음 플러그인 기능이 수정되거나 삭제되었습니다. code을 업데이트하십시오.

  • 액션 시트
  • 브라우저
  • 카메라
  • 장치
  • 위치 정보
  • 구글 맵
  • 로컬 알림
  • 푸시 알림
  • 상태 바

액션 시트

  • 업데이트 하기 androidxMaterialVersion __CAPGO_KEEP_0__을 1.8.0.

브라우저

  • 업데이트 하기 androidxBrowserVersion __CAPGO_KEEP_0__을 1.5.0.

카메라

  • Android 13에서 미디어 이미지 읽기 권한 (<uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/>)을 추가하세요. AndroidManifest.xml.
  • 업데이트 하기 androidxMaterialVersion __CAPGO_KEEP_0__을 1.8.0.
  • 업데이트 하기 androidxExifInterfaceVersion __CAPGO_KEEP_0__ 1.3.6.

__CAPGO_KEEP_0__

  • __CAPGO_KEEP_1__ DeviceId.uuid __CAPGO_KEEP_2__ DeviceId.identifier.
  • __CAPGO_KEEP_3__ DeviceInfo.name __CAPGO_KEEP_4__ __CAPGO_KEEP_5__.

__CAPGO_KEEP_6__

  • __CAPGO_KEEP_7__ playServicesLocationVersion __CAPGO_KEEP_8__ 21.0.1.

__CAPGO_KEEP_9__

  • __CAPGO_KEEP_10__
    • googleMapsPlayServicesVersion 로컬 알림 18.1.0.
    • googleMapsUtilsVersion 로컬 알림 3.4.0.
    • googleMapsKtxVersion 로컬 알림 3.4.0.
    • googleMapsUtilsKtxVersion 로컬 알림 3.4.0.
    • kotlinxCoroutinesVersion 로컬 알림 1.6.4.
    • androidxCoreKTXVersion 로컬 알림 1.10.0.
    • kotlin_version 로컬 알림 1.8.20.

로컬 알림

  • Android 13을 대상으로 로컬 알림을 예약하려면 새로운 런타임 권한 검사를 호출해야 합니다. SDK 33. Call checkPermissions() 그리고 requestPermissions() 따라서.

푸시 알림

  • Android 13에서 푸시 알림을 받으려면 SDK 33을 대상으로 하는 새로운 런타임 권한 검사를 필요로 합니다. Call checkPermissions() 그리고 requestPermissions() 따라서.
  • 변수를 firebaseMessagingVersion Status Bar 23.1.2.

iOS에서 기본 상태栏 애니메이션은

  • __CAPGO_KEEP_0__을 업데이트하고 이러한 단계를 따르면 __CAPGO_KEEP_1__ 4에서 __CAPGO_KEEP_2__ 5로 프로젝트를 성공적으로 업데이트한 것으로 확인됩니다. 모든 기능과 플러그인이 예상대로 작동하는지 확인하기 위해 응용 프로그램을 철저히 테스트하세요. FADE.

By following these steps and updating your code accordingly, you should now have successfully updated your project from Capacitor 4 to Capacitor 5. Make sure to test your application thoroughly to ensure that all features and plugins are working as expected.

Keep going from Updating from Capacitor 4 to Capacitor 5: A Step-by-Step Guide

Updating from __CAPGO_KEEP_0__ 4 to __CAPGO_KEEP_1__ 5: A Step-by-Step Guide Capacitor 4에서 Capacitor 5로 프로젝트를 업데이트하는 단계별 안내입니다. __CAPGO_KEEP_0__ 4에서 __CAPGO_KEEP_1__ 5로 프로젝트를 업데이트하는 단계별 안내입니다. Capgo 플러그인 디렉토리 Capgo 플러그인 디렉토리에서 제품 워크플로우를 위해 Capacitor 플러그인들에 의해 Capgo Capacitor 플러그인들에 의해 Capgo의 구현 세부 정보를 위해 플러그인 추가 또는 업데이트 플러그인 추가 또는 업데이트의 구현 세부 정보를 위해 아이오닉 엔터프라이즈 플러그인 대체 아이오닉 엔터프라이즈 플러그인 대체의 제품 워크플로우를 위해, 그리고 Capgo 네이티브 빌드 Capgo 네이티브 빌드의 제품 워크플로우를 위해

Capacitor 앱에 대한 실시간 업데이트

Capgo 버그가 활성화된 경우, 앱 스토어 승인까지 며칠 기다리지 않고 Capgo를 통해 패치를 배포하세요. 사용자는 배경에서 업데이트를 받으며, 네이티브 변경 사항은 일반적인 검토 경로에 남게 됩니다.

시작하기

블로그에서 최신 뉴스

Capgo은 전문적인 모바일 앱을 만들기 위해 필요한 최고의洞察력을 제공합니다.