toJson method

Object? toJson()

Converts the value to JSON if possible.

Implementation

Object? toJson() => (value as dynamic)?.toJson();