toJson method

Map<String, dynamic> toJson()

Convert to JSON.

Implementation

Map<String, dynamic> toJson() => {
      'sectionId': sectionId,
      'index': index,
      if (title != null) 'title': title,
      if (description != null) 'description': description,
      'blocks': blocks.map((b) => b.toJson()).toList(),
    };