Youtube Video Stream Url
Step 1
We cannot directly remove the time stamp from Youtube Video Stream Url but using the intl.dart package we can easily filter the date stamp from time stamp. So open your flutter project’s pubspec.yaml in code .
dependencies: flutter: sdk: flutter flutter_youtube: ^2.0.0
flutter pub get
import 'package:flutter/material.dart'; import 'package:flutter_youtube/flutter_youtube.dart'; void main() => runApp(new MyApp()); class MyApp extends StatefulWidget { @override _MyAppState createState() => new _MyAppState(); } class _MyAppState extends State<MyApp> { TextEditingController textEditingControllerUrl = new TextEditingController(); @override initState() { super.initState(); } void playYoutubeVideoEdit() { FlutterYoutube.playYoutubeVideoByUrl( apiKey: "You Api Key Here", videoUrl: textEditingControllerUrl.text, ); } @override Widget build(BuildContext context) { return new MaterialApp( debugShowCheckedModeBanner: false, home: new Scaffold( appBar: new AppBar( backgroundColor: Colors.orange, title: new Text('Youtube Player'), ), body: Center( child: Container( margin: EdgeInsets.only(left: 16.0), child: TextFormField( controller: textEditingControllerUrl, decoration: InputDecoration( hintText: 'Youtube url here...', filled: true, prefixIcon: Icon( Icons.video_library, color: Colors.red[900], size: 28.0, ), suffixIcon: IconButton( icon: Icon(Icons.play_arrow), onPressed: () { playYoutubeVideoEdit(); })), ), ), ), ), ); } }