getLabel method

String getLabel(
  1. String attribute
)

Implementation

String getLabel(String attribute) {
  String label = labels[attribute] ?? '';
  if (label.isEmpty) {
    label = attribute;
    label = label.replaceAll('_', ' ');
    label = _capitalize(label);
  }

  return label;
}