getItem method

Future<Item> getItem()

Gets the parent item of this artifact as an Item model.

final item = await artifact.getItem();

Implementation

Future<Item> getItem() async {
  final targetKref = itemKref ?? revisionKref.itemKref;
  final response = await client.getItemByKref(targetKref.uri);
  return Item(response, client);
}