【发布时间】:2021-12-12 17:03:05
【问题描述】:
我正在使用 import @react-native-firebase/firestore Lib 我想在 firestore 数据库中插入一个位置类型的地理点问题是不断触发错误提示
不能将类作为函数调用
这是我调用函数的方式,位置是我的 firestore 字段:
location : firestore.GeoPoint(lat, long)
我也尝试从以下位置单独导入 firebase:
import firebase from '@react-native-firebase/app'
然后:
location : firebase.firestore.GeoPoint(lat, long)
我仍然遇到同样的错误,我也尝试过:
firebase.firestore.GeoPoint.latitude = lat ;
...
没有成功,请帮忙
【问题讨论】:
标签: reactjs firebase react-native google-cloud-firestore