Search code examples
node.jscordovanpmcordova-plugins

How do i make a cordova plugin into an npm package


I have a Cordova plugin and I need to make an npm package how do I do this.

Are there any tutorials etc.

Many Thanks,

Laurence


Solution

  • If you want to contribute a package to npm for public usage you can follow this instruction. If you want to have a private package it's a paid option.

    If you already set up a GitHub repository with your plugin correctly you can use it without adding it to the npm. Just use your repository URL when you installing it:

    cordova plugin add https://github.com/apache/cordova-plugin-console.git