我正在使用 firebase 實時資料庫處理一些檔案。我需要洗掉一個我無權通過 SDK 在客戶端讀取它的檔案。為了做到這一點,我需要知道 id 是什么,所以我應該將它存盤在我的資料庫(mongo)中,當我需要洗掉 firebase 上的檔案時,我只需從我的資料庫中獲取它并洗掉它。
我看了一下
uj5u.com熱心網友回復:
您正在查看的答案是關于Firestore而不是您正在使用的實時資料庫。參考有一個屬性,而不是:keyid
console.log('New Key', notsRef.key)
// to get child node's key
const childNotesRef = notsRef.push({
..._.omit(notification, 'to'),
});
console.log(childNotesRef.key)
轉載請註明出處,本文鏈接:https://www.uj5u.com/qiye/460813.html
標籤:javascript 打字稿 火力基地 firebase-实时数据库
