recommendation property

String get recommendation

Get recommendation for this dependency

Implementation

String get recommendation {
  switch (status) {
    case DependencyStatus.used:
      if (section == DependencySection.dependencies) {
        return 'Keep in dependencies';
      } else {
        return 'Keep in dev_dependencies';
      }
    case DependencyStatus.testOnly:
      if (section == DependencySection.dependencies) {
        return 'Move to dev_dependencies';
      } else {
        return 'Move to dependencies';
      }
    case DependencyStatus.unused:
      return 'Remove (unused)';
  }
}