fromJson static method

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

static method to create and return JsonObject. It takes Map<String, dynamic> that represents data as an argument

Example:

final apiVersion = {'Sample API v1': 'description and usage',
                    'Sample API v2': 'description and usage'};
final apiDocObject = ProjectDataObject.fromJson(apiVersion);

Implementation

static JsonObject fromJson(Map<String, dynamic> json) {
  return JsonObject(json);
}