Expost remove listeners for firebase messaging
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 42/100
- Issue 類型
- 功能
- 描述清晰度
- 基本清楚
- 活躍度
- 停滯
- 技術堆疊
- firebase, typescript
- 領域
- mobile
研究方向
首先定位 onMessage 和 onNotificationTap 的 messaging 實作,然後檢查每個 listener 是如何註冊和保留的。當兩個 API 都提供一種移除其 listener 的方式(類似 authentication listener 範例),且現有的 messaging 行為維持不變時,工作就完成了。
由索引模型根據 Issue 內容生成。
描述
When listening to onMessage, onNotificationTap there is no way to remove listeners and is leading to memory leak
// on message
firebase()
.messaging()
.onMessage(async (remoteMessage) => {
console.log({ remoteMessage });
});
// on notification tap
firebase()
.messaging()
.onNotificationTap((message) => {
console.log({ message });
});
there is no way to remove listeners as there is for firebase auth
firebase().auth().addAuthStateChangeListener
firebase().auth().removeAuthStateChangeListener
- 主要語言
- TypeScript
- 星號
- 62
- 分支
- 53
- 平均合併
- 8 天 4 小時
- 30 天內合併 PR
- 2
環境準備
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
NativeScript/firebase 的其他 Issue
-
難度 3/5 1-2 天 新手友好度 48/100
NativeScript/firebase#292 ·
-
難度 3/5 1-2 天 新手友好度 35/100
NativeScript/firebase#289 ·
-
難度 4/5 3-5 天 新手友好度 35/100
NativeScript/firebase#288 · 4 個 reaction ·
-
[messaging-core][ios] getCurrentToken stalls可能重新可做 @triniwiz 於 180 天前認領,目前沒有進行中的 PR。 未關閉bug ios
NativeScript/firebase#287 · 已指派 1 人 ·
-
Uh-Oh Shazam未關閉
難度 4/5 3-5 天 新手友好度 20/100
NativeScript/firebase#286 ·
查看 NativeScript/firebase 的全部 Issue
相似的 Issue
-
docs
難度 1/5 1 小時以內 新手友好度 68/100
remix-run/react-router#15558 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 78/100
solana-foundation/pay-kit#341 ·
維護者通常 1 天內回覆
-
難度 1/5 1-3 小時 新手友好度 88/100
supabase/agent-skills#607 ·
-
enhancement
難度 2/5 1-3 小時 新手友好度 88/100
-
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆