搜尋套件、儲存庫與 APP 分類

youtube_player_flutter 封面
套件詳情v10.0.1

youtube_player_flutter

使用官方 iFrame 播放器 API 播放或串流內嵌 YouTube 影片的 Flutter 插件。此插件支援 Android 與 iOS。

AndroidiOSWebmacOSWindows
近 30 天下載
21.6萬
喜歡數
1710
Pub 分數
160

安裝套件

flutter pub add youtube_player_flutter

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

一個 Flutter 插件,使用官方 iFrame Player API 實現 YouTube 影片的內聯播放。它支援多個平台,包括 Android、iOS、Web、macOS 和 Windows,提供一種無縫將 YouTube 內容整合至 Flutter 應用程式的途徑。該插件提供可自訂的影片播放器,支援各種播放控制、事件與畫質設定。開發者可輕鬆在應用中嵌入與管理 YouTube 影片,無需依賴外部播放器或複雜的變通方法。

適用情境

  • 在行動應用程式中嵌入 YouTube 影片
  • 在網頁應用中串流影片
  • 建立影片教學或內容中心
  • 在教育類應用程式中整合影片播放
  • 建構豐富的媒體 Flutter 經驗

主要特色

  • 支援 iframe 播放器 API
  • 跨平台相容性
  • 可自定義的播放器UI
  • 播放狀態的事件處理
  • 跨裝置的響應式設計
  • 影片品質選擇

適合對象

  • 開發媒體密集型應用的開發者
  • 教育或教程平台
  • 內容分發應用
  • 需要嵌入影片串流的應用程式
  • Flutter 團隊針對多個平台

使用建議

  • 需要互聯網連接以加載影片
  • 與原生播放器相比,自訂功能有限
  • 取決於 YouTube 的 API 可用性
  • 對低階設備的潛在效能影響
  • 某些平台可能需要額外的權限

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

Youtube Player iFrame Youtube Player Flutter

Youtube Player for Flutter

A Flutter monorepo for seamless YouTube video playback, powered by the official iFrame Player API.

Stars Issues BSD-3 License


Packages

Package Version Demo Description Platforms
youtube_player_flutter pub demo Batteries-included YouTube player with built-in controls, gestures, and live stream UI Android, iOS, macOS, Web
youtube_player_iframe pub demo Full-control Flutter port of the YouTube iFrame API. Build your own UI. Android, iOS, macOS, Web
youtube_player_iframe_web pub Web platform implementation for youtube_player_iframe (added automatically) Web

Which package should I use?

youtube_player_flutter: just want a player that works

The quickest path to YouTube playback in your app. It ships with ready-made controls, a progress bar, drag-to-seek, pinch-to-fullscreen, and a live stream UI, all out of the box. Drop it in, point it at a video ID, and you're done.

flutter pub add youtube_player_flutter

Best for: apps that want a polished, functional player with minimal setup.


youtube_player_iframe: want full control over the player

A lower-level package that gives you the complete YouTube iFrame API. You own the UI; the package handles playback state, playlists, metadata, fullscreen transitions, thumbnails, and more. Includes a lazy-loading thumbnail widget perfect for video lists.

flutter pub add youtube_player_iframe

Best for: apps with a custom player design, complex playback logic, or playlist management needs.


youtube_player_iframe_web: you probably don't need to add this

This is the web platform implementation consumed automatically by youtube_player_iframe. You only need to add it directly if you're building a platform plugin or working inside this monorepo.


License

BSD-3-Clause. See LICENSE for details.

This project uses the YouTube IFrame Player API. By using these packages, you agree to the YouTube API Services Terms of Service.

API method documentation is adapted from the YouTube IFrame Player API Reference, © Google LLC, licensed under CC BY 4.0. See NOTICE for details.

所屬分類

依賴

依賴清單 1 項

原始碼儲存庫

使用此套件的專案