How about something like this? Yes documentation is good like you said, but maybe also include user action feedback? Just would involve a bit of work.
# Use Case 1 ``` $ cordova create project $ cd project $ npm install --no-save cordova-plugin-camera $ cordova plugin add cordova-plugin-camera > Cordova has discovered that plugin `cordova-plugin-camera` already exists but > not saved. Missing configurations will be added to package.json. Cordova will > not override or save the plugin to package.json. For more information: > https://cordova.io/frequent-issues ``` or ``` $ cordova create project $ cd project $ cp -R ~/some-plugin ./node_modules/ $ cordova plugin add cordova-plugin-camera > Cordova has discovered that plugin `cordova-plugin-camera` already exists but > not saved. Missing configurations will be added to package.json. Cordova will > not override or save the plugin to package.json. For more information: > https://cordova.io/frequent-issues ``` I believe `cordova plugin add` should still update `package.json` with the plugin configurations if it does not today. ``` "cordova": { "plugins": { "cordova-plugin-camera": {} } } ``` # Use Case 2 ``` $ cordova create project $ cd project $ npm install --no-save cordova-plugin-camera $ vi package.json -- I add manually the Cordova plugin configs $ cordova plugin add cordova-plugin-camera > Cordova has discovered that plugin `cordova-plugin-camera` already exists but > not saved. Cordova will not override or save the plugin to package.json. For > more information: https://cordova.io/frequent-issues ``` Only difference is I also had plugin configs and the feedback message drops about adding missing configs. We also create the frequent-issues page that would explain a bit more why something happens. Anyways, I understand now the use case. [ Full content available at: https://github.com/apache/cordova-fetch/issues/47 ] This message was relayed via gitbox.apache.org for [email protected]
