background_runtime_web 0.1.1 copy "background_runtime_web: ^0.1.1" to clipboard
background_runtime_web: ^0.1.1 copied to clipboard

Platformweb

Web implementation of the background_runtime plugin.

background_runtime_web #

Web implementation of the background_runtime Flutter plugin.

Best-effort support. Some native features (foreground service, persistent notifications) are unavailable on the web platform.

Capabilities #

  • Downloads: Triggers browser download via anchor element (no CORS restrictions, no progress tracking).
  • Audio playback: HTMLAudioElement with explicit play() and autoplay policy handling.
  • Notification actions: Media Session API (previoustrack/nexttrack/play/pause/stop) with keyboard media-key fallback.
  • Album art: Set as MediaMetadata artwork when AudioTrack.albumArt is provided.
  • Lifecycle events: Reports initialized and terminated states.

Known Limitations #

  • No true background execution (browsers do not support it).
  • Audio playback stops when the page is hidden on mobile.
  • Downloads cannot be paused or resumed.
  • Previous/next actions require Media Session API support or media keys.
  • Download progress tracking is not available (best-effort).