dereference method
Implementation
Example dereference({
required Map<String, Example>? components,
}) {
if (ref == null) {
return this;
}
final eRef = components?[ref?.split('/').last];
if (eRef == null) {
throw Exception(
"\n\n'$ref' is not a valid component example reference\n",
);
}
_checkReferenceTypes(ref, eRef, this);
return eRef.copyWith(
ref: ref,
summary: summary ?? eRef.summary,
description: description ?? eRef.description,
);
}