FLUTTER ECOSYSTEM

kevlatus/flutter_broadcasts

一個用於透過 Android 意圖和 iOS 通知發送和接收廣播的外掛程式。

flutter_broadcasts 專案封面
Stars
17
Forks
57
最近推送(UTC)
2024年7月31日
專案狀態
未封存
Kevin Latusinski GitHub avatar
GITHUB User

Kevin Latusinski ↗

語言DartKotlinRubySwiftObjective-C

此儲存庫發佈的套件

使用的依賴

依賴清單 2 項
  • flutter{"sdk":"flutter"}
  • flutter_test開發依賴{"sdk":"flutter"}

原始 README

以下為英文專案原文快照,最新內容請造訪 GitHub。

展開 / 收合專案 README

https://img.shields.io/pub/v/flutter_broadcasts

Flutter Broadcasts

A plugin for sending and receiving broadcasts with Android intents and iOS notifications. The API is inspired by Android's BroadcastReceivers and uses the NotificationCenter internally on iOS.

Quick Start

First install the package via pub.dev. Then subscribe to broadcasts like this:

BroadcastReceiver receiver = BroadcastReceiver(
  names: <String>["de.kevlatus.broadcast"],
);
receiver.messages.listen(print);
receiver.start();

Roadmap

This package is currently under construction. Below you can find a quick overview of its implementation status. Contributions are welcome, if you are missing features.

  • [x] implement broadcast receiver on Android
  • [x] implement broadcast sending on Android
  • [ ] implement NSNotificationCenter subscriptions on iOS
  • [ ] implement NSNotificationCenter notifications on iOS

Contributions

Contributions are much appreciated, but keep in mind that this package is supposed to be generic and only expose native broadcast APIs like Android's BroadcastReceivers and the iOS NotificiationCenter. Consider creating separate packages for sending and receiving specific broadcast instances.

If you have any ideas for extending this package to other platforms, feel free to open a pull request or raise an issue.