of static method

CardRegistry of(
  1. BuildContext context
)

Implementation

static CardRegistry of(BuildContext context) {
  final reg =
  context.dependOnInheritedWidgetOfExactType<DefaultCardRegistry>();
  assert(
  reg != null,
  'DefaultCardRegistry not found in the widget tree. '
      'Wrap your subtree with DefaultCardRegistry.',
  );
  return reg!.cardRegistry;
}