fromJson static method

Collection? fromJson(
  1. dynamic json, {
  2. LinkHrefNormalizer normalizeHref = linkHrefNormalizerIdentity,
})

Parses a Contributor from its RWPM JSON representation.

A contributor can be parsed from a single string, or a full-fledged object. The links' href and their children's will be normalized recursively using the provided normalizeHref closure. If the contributor can't be parsed, a warning will be logged with warnings.

Implementation

static Collection? fromJson(dynamic json,
        {LinkHrefNormalizer normalizeHref = linkHrefNormalizerIdentity}) =>
    Contributor.fromJson(json, normalizeHref: normalizeHref)?.toCollection();