fromJson static method

IconData? fromJson(
  1. Map<String, dynamic>? json
)

Implementation

static IconData? fromJson(Map<String, dynamic>? json) {
  if (json == null || json['codePoint'] == null) {
    return null;
  }

  return IconData(
    json['codePoint'] as int,
    fontFamily: json['fontFamily'] as String? ?? 'MaterialIcons',
    fontPackage: json['fontPackage'] as String?,
  );
}