examples/cordova1/plugins/branch-cordova-sdk/src/scripts/npm/processConfigXml.js
function getProjectModule(context) {
    const projectRoot = getProjectRoot(context);
    const projectPath = path.join(projectRoot, "platforms", "ios");

    try {
      // pre 5.0 cordova structure
      return context
        .requireCordovaModule("cordova-lib/src/plugman/platforms")
        .ios.parseProjectFile(projectPath);
    } catch (e) {
      try {
        // pre 7.0 cordova structure
        return context
          .requireCordovaModule("cordova-lib/src/plugman/platforms/ios")
          .parseProjectFile(projectPath);
      } catch (e) {
        // post 7.0 cordova structure
        return getProjectModuleGlob(context);
      }
    }
  }
function getProjectModule(context) {
    const projectRoot = getProjectRoot(context);
    const projectPath = path.join(projectRoot, "platforms", "ios");

    try {
      // pre 5.0 cordova structure
      return context
        .requireCordovaModule("cordova-lib/src/plugman/platforms")
        .ios.parseProjectFile(projectPath);
    } catch (e) {
      try {
        // pre 7.0 cordova structure
        return context
          .requireCordovaModule("cordova-lib/src/plugman/platforms/ios")
          .parseProjectFile(projectPath);
      } catch (e) {
        // post 7.0 cordova structure
        return getProjectModuleGlob(context);
      }
    }
  }
function getProjectModule ( context ) { const projectRoot = getProjectRoot ( context ) ; const projectPath = path . join ( projectRoot , "platforms" , "ios" ) ; try { // pre 5.0 cordova structure return context . requireCordovaModule ( "cordova-lib/src/plugman/platforms" ) . ios . parseProjectFile ( projectPath ) ; } catch ( e ) { try { // pre 7.0 cordova structure return context . requireCordovaModule ( "cordova-lib/src/plugman/platforms/ios" ) . parseProjectFile ( projectPath ) ; } catch ( e ) { // post 7.0 cordova structure return getProjectModuleGlob ( context ) ; } } }
read iOS project module from cordova context
read iOS project module from cordova context