toJson method

  1. @override
Map<String, dynamic> toJson()
override

Serialises this node and all its children into the SDUI JSON format.

Implementation

@override
Map<String, dynamic> toJson() => {
  'widget': 'Padding',
  'properties': {'padding': padding},
  if (child != null) 'child': child!.toJson(),
};