youtubeVideoProvider top-level property
Implementation
final youtubeVideoProvider = LinkProvider(_youtubeVideo,
tags: {Tags.socialMedia},
scheme: 'youtube://',
handleExtractor: (uri) {
if (uri.host.contains('youtu') && uri.path.contains('watch')) {
return uri.queryParameters['v'];
}
},
webLinkGenerator: (input) =>
"https://www.youtube.com/watch?v=${input.handle}",
appLinkGenerator: (input) => "youtube://watch?v=${input.handle}");