javascript - 如何更新 Cloud Firestore js 中的数组
问题描述
我正在与 Google 的 Cloud Firestore 合作,但我无法更新数组......所以,如果有人有解决方案。
docRef.get()
.then(function(doc) {
if ( doc.exists ) { db.collection("collection")
.doc("document").update({ "array"[0]: true })
.then(function() {
console.log("Changed !");
})
} })
解决方案
推荐阅读
- android - 如何恢复已导出的 Room 数据库?
- python - 做什么而不是分配 np.ndarray.data?
- magento - Magento 2.3 显示带有运输选项的文本
- java - 如何遍历可选中的嵌套列表?
- powershell - 基于 PowerShell 注释的帮助不适用于脚本
- c# - C# 使用查询中的多行填充标签
- c++ - C++ 函数模板是否鼓励弱类型化?
- c# - 使用 c#/visual studio 在 Mac 上的 Docker 中访问/查询 SQLServer
- select - 如何从 bigquery 中的表中仅选择第一行 - 以降低成本
- c# - C# 将 JSON 字符串反序列化为对象