code: function () {
    var composerInstallDirectory = 'vendor';
  
    var exists = null;
    try {
      exists = fs.statSync(getComposerConfigPath());
    } catch (e) {}
  
    if (exists !== null) {
      var composerConfig = JSON.parse(fs.readFileSync(getComposerConfigPath()));
      if ('config' in composerConfig && 'vendor-dir' in composerConfig.config) {
        composerInstallDirectory = composerConfig.config['vendor-dir'];
      }
    }
    return composerInstallDirectory;
  }
docs: Composer.json can specify a custom vendor directory Let's get it if we can!