configStringList function
Reads a List<String> from json at key. Returns null if missing or wrong type.
Implementation
List<String>? configStringList(Map<String, Object?> json, String key) {
final value = json[key];
return value is List ? value.cast<String>() : null;
}