fromString static method

WorkoutAlertMetric fromString(
  1. String metric
)

Creates a new workout alert metric from a string

Implementation

static WorkoutAlertMetric fromString(String metric) {
  return WorkoutAlertMetric.values.firstWhere((e) => e.symbol == metric);
}