mask<T extends Widget> method

  1. @experimental
void mask<T extends Widget>({
  1. String? name,
  2. String? description,
})

Mask given widget type T (or subclasses of T) in the replay. Note: masking rules are called in the order they're added so if a previous rule already makes a decision, this rule won't be called.

Implementation

@experimental
void mask<T extends Widget>({String? name, String? description}) {
  assert(T != SentryMask);
  assert(T != SentryUnmask);
  _userMaskingRules.add(SentryMaskingConstantRule<T>(
    mask: true,
    name: name ?? T.toString(),
    description: description,
  ));
}