SimpleLink.fromJson constructor

SimpleLink.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory SimpleLink.fromJson(Map<String, Object?> json) {
  return SimpleLink(
    id: json[r'id'] as String?,
    styleClass: json[r'styleClass'] as String?,
    iconClass: json[r'iconClass'] as String?,
    label: json[r'label'] as String?,
    title: json[r'title'] as String?,
    href: json[r'href'] as String?,
    weight: (json[r'weight'] as num?)?.toInt(),
  );
}