GithubHelp home page GithubHelp logo

capacitor-plugin-to-v4's Introduction

capacitor-plugin-to-v4

This is a command tool that automatically update the capacitor plugin version 3 to 4. This library follows the changes in https://github.com/ionic-team/create-capacitor-plugin/commit/03027bf603626ebfdba084cb9d9a1a359d008554

At least, this library is used to make the following plugins Capacitor4-compatible.

  • @capacitor-community/admob
  • @capacitor-community/stripe
  • @capacitor-community/facebook-login

usage

run npx command into plugin folder.

% npx @rdlabo/capacitor-plugin-to-v4  

result

Need to install the following packages:
@rdlabo/capacitor-plugin-to-v4
Ok to proceed? (y) y

[info] @rdlabo/capacitor-plugin-to-v4 path is /Users/sakakibara/.npm/_npx/8b6523b6da3b9745/node_modules/@rdlabo/capacitor-plugin-to-v4/src
[info] working path is /Users/sakakibara/dev/capacitor-stripe
[info] get update lines of /Users/sakakibara/dev/capacitor-stripe/package.json
[info] get update lines of /Users/sakakibara/dev/capacitor-stripe/CapacitorCommunityStripe.podspec and /Users/sakakibara/dev/capacitor-stripe/ios/Podfile
[info] get update lines of /Users/sakakibara/dev/capacitor-stripe/ios/Plugin.xcodeproj/project.pbxproj
[info] get update lines of /Users/sakakibara/dev/capacitor-stripe/android/build.gradle
[info] get update lines of /Users/sakakibara/dev/capacitor-stripe/android/gradle/wrapper/gradle-wrapper.properties
[success] write /Users/sakakibara/dev/capacitor-stripe/package.json
[success] write /Users/sakakibara/dev/capacitor-stripe/CapacitorCommunityStripe.podspec
[success] write /Users/sakakibara/dev/capacitor-stripe/ios/Podfile
[success] write /Users/sakakibara/dev/capacitor-stripe/ios/Plugin.xcodeproj/project.pbxproj
[success] write /Users/sakakibara/dev/capacitor-stripe/android/build.gradle
[success] write /Users/sakakibara/dev/capacitor-stripe/android/gradle/wrapper/gradle-wrapper.properties
[success] write /Users/sakakibara/dev/capacitor-stripe/android/gradlew
success migrate to v4๐ŸŽ‰
Next step: You should run `npm install`

Troubleshooting

removed jcenter() before run

If plugin had manually removed jcenter(), will not work well. When this, you should check android/build.gradle and add mavenCentral() manually.

For the correct configuration, please click here: https://github.com/ionic-team/create-capacitor-plugin/commit/03027bf603626ebfdba084cb9d9a1a359d008554#diff-51795f26cbdfdde24931f6d0f9d6f047f4617fc6a6cb850029cd78c8e0e9b90d

capacitor-plugin-to-v4's People

Contributors

rdlabo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

capacitor-plugin-to-v4's Issues

Dependency issues

Thanks for this tool! Might I suggest that you not change these:

const changePackageVersion = {
  '"prettier"': '2.3.0',
  '"prettier-plugin-java"': '1.0.2',
  '"typescript"': '4.1.5',

First of all, those are old versions you have there, and AFAIK changing those has little to do with Capacitor 4 vs 3. Second, I think using a "^" version is much preferred to an absolute version, since that allows non-breaking updates.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.