linkRegExp property

RegExp linkRegExp

Implementation

RegExp get linkRegExp {
  final customRegExp = _linkRegExp;
  if (customRegExp != null) {
    return customRegExp;
  }
  switch (widget.linkType) {
    case LinkType.video:
      if (youtubeRegExp.hasMatch(_link)) {
        return youtubeRegExp;
      }
      return videoRegExp;
    case LinkType.image:
      return imageRegExp;
  }
}