getAboutPageByUsername method

Future<ChannelAbout> getAboutPageByUsername(
  1. dynamic username
)

Gets the info found on a YouTube Channel About page. username must be either a Username or a string which is parsed to a Username

WARNING: As of v2.2.0 this is broken due to yt updates.

Implementation

Future<ChannelAbout> getAboutPageByUsername(dynamic username) async {
  username = Username.fromString(username);

  final page =
      await ChannelAboutPage.getByUsername(_httpClient, username.value);

  return ChannelAbout(
    page.description,
    page.viewCount,
    page.joinDate,
    page.title,
    [
      for (final e in page.avatar)
        Thumbnail(Uri.parse(e['url']), e['height'], e['width']),
    ],
    page.country,
    page.channelLinks,
  );
}