EddyVerbruggen / nativescript-plugin-firebase

:fire: NativeScript plugin for Firebase
https://firebase.google.com
MIT License
1.01k stars 444 forks source link

Error on using firestore FieldPath #1610

Open maciej-bielecki opened 4 years ago

maciej-bielecki commented 4 years ago

Hi there, I'm trying to use FieldPath from firestore because my path contains dots (.) basically its an email. doc is here: https://firebase.google.com/docs/reference/js/firebase.firestore.FieldPath.html

I need to use FieldPath because otherwise dot is recognized as nested path.

my usage is:

import { firestore } from 'nativescript-plugin-firebase';
...
var fieldPath = new firestore.FieldPath('foo@bar.com');
writeBatch.update(bucketAccessRef, fieldPath, {key: "value" });

But I'm getting error: ERROR TypeError: nativescript_plugin_firebase__WEBPACK_IMPORTED_MODULE_4__.firestore.FieldPath is not a constructor