@react-native-firebase/firestore 23.8.6 → 24.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +35 -0
- package/RNFBFirestore.podspec +2 -1
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestoreCollectionModule.java +17 -4
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestoreDocumentModule.java +2 -2
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestorePipelineExecutor.java +1243 -0
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestorePipelineNodeBuilder.java +3919 -0
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestorePipelineParser.java +1735 -0
- package/android/src/reactnative/java/io/invertase/firebase/firestore/ReactNativeFirebaseFirestoreSerialize.java +1 -1
- package/dist/module/FieldPath.js +59 -0
- package/dist/module/FieldPath.js.map +1 -0
- package/dist/module/FieldValue.js +82 -0
- package/dist/module/FieldValue.js.map +1 -0
- package/{lib → dist/module}/FirestoreAggregate.js +31 -43
- package/dist/module/FirestoreAggregate.js.map +1 -0
- package/dist/module/FirestoreBlob.js +56 -0
- package/dist/module/FirestoreBlob.js.map +1 -0
- package/dist/module/FirestoreCollectionReference.js +70 -0
- package/dist/module/FirestoreCollectionReference.js.map +1 -0
- package/{lib → dist/module}/FirestoreDocumentChange.js +12 -15
- package/dist/module/FirestoreDocumentChange.js.map +1 -0
- package/dist/module/FirestoreDocumentReference.js +170 -0
- package/dist/module/FirestoreDocumentReference.js.map +1 -0
- package/dist/module/FirestoreDocumentSnapshot.js +88 -0
- package/dist/module/FirestoreDocumentSnapshot.js.map +1 -0
- package/dist/module/FirestoreFilter.js +146 -0
- package/dist/module/FirestoreFilter.js.map +1 -0
- package/dist/module/FirestoreGeoPoint.js +80 -0
- package/dist/module/FirestoreGeoPoint.js.map +1 -0
- package/{lib → dist/module}/FirestorePath.js +5 -12
- package/dist/module/FirestorePath.js.map +1 -0
- package/{lib → dist/module}/FirestorePersistentCacheIndexManager.js +11 -4
- package/dist/module/FirestorePersistentCacheIndexManager.js.map +1 -0
- package/dist/module/FirestoreQuery.js +298 -0
- package/dist/module/FirestoreQuery.js.map +1 -0
- package/{lib → dist/module}/FirestoreQueryModifiers.js +25 -136
- package/dist/module/FirestoreQueryModifiers.js.map +1 -0
- package/dist/module/FirestoreQuerySnapshot.js +98 -0
- package/dist/module/FirestoreQuerySnapshot.js.map +1 -0
- package/dist/module/FirestoreSnapshotMetadata.js +38 -0
- package/dist/module/FirestoreSnapshotMetadata.js.map +1 -0
- package/dist/module/FirestoreStatics.js +50 -0
- package/dist/module/FirestoreStatics.js.map +1 -0
- package/{lib → dist/module}/FirestoreTimestamp.js +39 -39
- package/dist/module/FirestoreTimestamp.js.map +1 -0
- package/dist/module/FirestoreTransaction.js +113 -0
- package/dist/module/FirestoreTransaction.js.map +1 -0
- package/dist/module/FirestoreTransactionHandler.js +137 -0
- package/dist/module/FirestoreTransactionHandler.js.map +1 -0
- package/dist/module/FirestoreVectorValue.js +75 -0
- package/dist/module/FirestoreVectorValue.js.map +1 -0
- package/dist/module/FirestoreWriteBatch.js +113 -0
- package/dist/module/FirestoreWriteBatch.js.map +1 -0
- package/dist/module/LoadBundleTask.js +70 -0
- package/dist/module/LoadBundleTask.js.map +1 -0
- package/dist/module/index.js +31 -0
- package/dist/module/index.js.map +1 -0
- package/dist/module/modular/Bytes.js +67 -0
- package/dist/module/modular/Bytes.js.map +1 -0
- package/dist/module/modular/FieldPath.js +25 -0
- package/dist/module/modular/FieldPath.js.map +1 -0
- package/dist/module/modular/FieldValue.js +37 -0
- package/dist/module/modular/FieldValue.js.map +1 -0
- package/dist/module/modular/GeoPoint.js +22 -0
- package/dist/module/modular/GeoPoint.js.map +1 -0
- package/dist/module/modular/Timestamp.js +22 -0
- package/dist/module/modular/Timestamp.js.map +1 -0
- package/dist/module/modular/VectorValue.js +25 -0
- package/dist/module/modular/VectorValue.js.map +1 -0
- package/dist/module/modular/query.js +222 -0
- package/dist/module/modular/query.js.map +1 -0
- package/dist/module/modular/snapshot.js +32 -0
- package/dist/module/modular/snapshot.js.map +1 -0
- package/dist/module/modular.js +229 -0
- package/dist/module/modular.js.map +1 -0
- package/dist/module/namespaced.js +298 -0
- package/dist/module/namespaced.js.map +1 -0
- package/dist/module/package.json +1 -0
- package/dist/module/pipelines/expressions.js +1273 -0
- package/dist/module/pipelines/expressions.js.map +1 -0
- package/dist/module/pipelines/index.js +32 -0
- package/dist/module/pipelines/index.js.map +1 -0
- package/dist/module/pipelines/pipeline-result.js +58 -0
- package/dist/module/pipelines/pipeline-result.js.map +1 -0
- package/dist/module/pipelines/pipeline-source.js +4 -0
- package/dist/module/pipelines/pipeline-source.js.map +1 -0
- package/dist/module/pipelines/pipeline.js +4 -0
- package/dist/module/pipelines/pipeline.js.map +1 -0
- package/dist/module/pipelines/pipeline_impl.js +42 -0
- package/dist/module/pipelines/pipeline_impl.js.map +1 -0
- package/dist/module/pipelines/pipeline_options.js +4 -0
- package/dist/module/pipelines/pipeline_options.js.map +1 -0
- package/dist/module/pipelines/pipeline_runtime.js +526 -0
- package/dist/module/pipelines/pipeline_runtime.js.map +1 -0
- package/dist/module/pipelines/pipeline_support.js +71 -0
- package/dist/module/pipelines/pipeline_support.js.map +1 -0
- package/dist/module/pipelines/pipeline_validate.js +183 -0
- package/dist/module/pipelines/pipeline_validate.js.map +1 -0
- package/dist/module/pipelines/stage_options.js +4 -0
- package/dist/module/pipelines/stage_options.js.map +1 -0
- package/dist/module/pipelines/types.js +2 -0
- package/dist/module/pipelines/types.js.map +1 -0
- package/dist/module/types/firestore.js +4 -0
- package/dist/module/types/firestore.js.map +1 -0
- package/dist/module/types/internal.js +4 -0
- package/dist/module/types/internal.js.map +1 -0
- package/dist/module/types/namespaced.js +338 -0
- package/dist/module/types/namespaced.js.map +1 -0
- package/{lib → dist/module}/utils/index.js +59 -114
- package/dist/module/utils/index.js.map +1 -0
- package/{lib → dist/module}/utils/serialize.js +58 -116
- package/dist/module/utils/serialize.js.map +1 -0
- package/{lib → dist/module}/utils/typemap.js +6 -20
- package/dist/module/utils/typemap.js.map +1 -0
- package/dist/module/version.js +5 -0
- package/dist/module/version.js.map +1 -0
- package/dist/module/web/RNFBFirestoreModule.android.js +5 -0
- package/dist/module/web/RNFBFirestoreModule.android.js.map +1 -0
- package/dist/module/web/RNFBFirestoreModule.ios.js +5 -0
- package/dist/module/web/RNFBFirestoreModule.ios.js.map +1 -0
- package/dist/module/web/RNFBFirestoreModule.js +387 -0
- package/dist/module/web/RNFBFirestoreModule.js.map +1 -0
- package/{lib → dist/module}/web/convert.js +60 -94
- package/dist/module/web/convert.js.map +1 -0
- package/dist/module/web/pipelines/pipeline.js +34 -0
- package/dist/module/web/pipelines/pipeline.js.map +1 -0
- package/dist/module/web/pipelines/pipeline_bridge_factory.js +217 -0
- package/dist/module/web/pipelines/pipeline_bridge_factory.js.map +1 -0
- package/dist/module/web/pipelines/pipeline_node_builder.js +294 -0
- package/dist/module/web/pipelines/pipeline_node_builder.js.map +1 -0
- package/dist/module/web/pipelines/pipeline_parser.js +21 -0
- package/dist/module/web/pipelines/pipeline_parser.js.map +1 -0
- package/dist/module/web/pipelines/pipeline_snapshot_serializer.js +89 -0
- package/dist/module/web/pipelines/pipeline_snapshot_serializer.js.map +1 -0
- package/dist/module/web/query.js +95 -0
- package/dist/module/web/query.js.map +1 -0
- package/dist/typescript/lib/FieldPath.d.ts +10 -0
- package/dist/typescript/lib/FieldPath.d.ts.map +1 -0
- package/dist/typescript/lib/FieldValue.d.ts +17 -0
- package/dist/typescript/lib/FieldValue.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreAggregate.d.ts +40 -0
- package/dist/typescript/lib/FirestoreAggregate.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreBlob.d.ts +11 -0
- package/dist/typescript/lib/FirestoreBlob.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreCollectionReference.d.ts +15 -0
- package/dist/typescript/lib/FirestoreCollectionReference.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreDocumentChange.d.ts +27 -0
- package/dist/typescript/lib/FirestoreDocumentChange.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreDocumentReference.d.ts +30 -0
- package/dist/typescript/lib/FirestoreDocumentReference.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreDocumentSnapshot.d.ts +30 -0
- package/dist/typescript/lib/FirestoreDocumentSnapshot.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreFilter.d.ts +52 -0
- package/dist/typescript/lib/FirestoreFilter.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreGeoPoint.d.ts +22 -0
- package/dist/typescript/lib/FirestoreGeoPoint.d.ts.map +1 -0
- package/dist/typescript/lib/FirestorePath.d.ts +12 -0
- package/dist/typescript/lib/FirestorePath.d.ts.map +1 -0
- package/dist/typescript/lib/FirestorePersistentCacheIndexManager.d.ts +16 -0
- package/dist/typescript/lib/FirestorePersistentCacheIndexManager.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreQuery.d.ts +39 -0
- package/dist/typescript/lib/FirestoreQuery.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreQueryModifiers.d.ts +59 -0
- package/dist/typescript/lib/FirestoreQueryModifiers.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreQuerySnapshot.d.ts +49 -0
- package/dist/typescript/lib/FirestoreQuerySnapshot.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreSnapshotMetadata.d.ts +8 -0
- package/dist/typescript/lib/FirestoreSnapshotMetadata.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreStatics.d.ts +23 -0
- package/dist/typescript/lib/FirestoreStatics.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreTimestamp.d.ts +33 -0
- package/dist/typescript/lib/FirestoreTimestamp.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreTransaction.d.ts +42 -0
- package/dist/typescript/lib/FirestoreTransaction.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreTransactionHandler.d.ts +26 -0
- package/dist/typescript/lib/FirestoreTransactionHandler.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreVectorValue.d.ts +17 -0
- package/dist/typescript/lib/FirestoreVectorValue.d.ts.map +1 -0
- package/dist/typescript/lib/FirestoreWriteBatch.d.ts +21 -0
- package/dist/typescript/lib/FirestoreWriteBatch.d.ts.map +1 -0
- package/dist/typescript/lib/LoadBundleTask.d.ts +16 -0
- package/dist/typescript/lib/LoadBundleTask.d.ts.map +1 -0
- package/dist/typescript/lib/index.d.ts +6 -0
- package/dist/typescript/lib/index.d.ts.map +1 -0
- package/dist/typescript/lib/modular/Bytes.d.ts +22 -0
- package/dist/typescript/lib/modular/Bytes.d.ts.map +1 -0
- package/dist/typescript/lib/modular/FieldPath.d.ts +4 -0
- package/dist/typescript/lib/modular/FieldPath.d.ts.map +1 -0
- package/dist/typescript/lib/modular/FieldValue.d.ts +8 -0
- package/dist/typescript/lib/modular/FieldValue.d.ts.map +1 -0
- package/dist/typescript/lib/modular/GeoPoint.d.ts +3 -0
- package/dist/typescript/lib/modular/GeoPoint.d.ts.map +1 -0
- package/dist/typescript/lib/modular/Timestamp.d.ts +3 -0
- package/dist/typescript/lib/modular/Timestamp.d.ts.map +1 -0
- package/dist/typescript/lib/modular/VectorValue.d.ts +4 -0
- package/dist/typescript/lib/modular/VectorValue.d.ts.map +1 -0
- package/dist/typescript/lib/modular/query.d.ts +93 -0
- package/dist/typescript/lib/modular/query.d.ts.map +1 -0
- package/dist/typescript/lib/modular/snapshot.d.ts +30 -0
- package/dist/typescript/lib/modular/snapshot.d.ts.map +1 -0
- package/dist/typescript/lib/modular.d.ts +69 -0
- package/dist/typescript/lib/modular.d.ts.map +1 -0
- package/dist/typescript/lib/namespaced.d.ts +13 -0
- package/dist/typescript/lib/namespaced.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/expressions.d.ts +723 -0
- package/dist/typescript/lib/pipelines/expressions.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/index.d.ts +31 -0
- package/dist/typescript/lib/pipelines/index.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline-result.d.ts +30 -0
- package/dist/typescript/lib/pipelines/pipeline-result.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline-source.d.ts +64 -0
- package/dist/typescript/lib/pipelines/pipeline-source.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline.d.ts +61 -0
- package/dist/typescript/lib/pipelines/pipeline.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline_impl.d.ts +21 -0
- package/dist/typescript/lib/pipelines/pipeline_impl.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline_options.d.ts +17 -0
- package/dist/typescript/lib/pipelines/pipeline_options.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline_runtime.d.ts +10 -0
- package/dist/typescript/lib/pipelines/pipeline_runtime.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline_support.d.ts +7 -0
- package/dist/typescript/lib/pipelines/pipeline_support.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/pipeline_validate.d.ts +9 -0
- package/dist/typescript/lib/pipelines/pipeline_validate.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/stage_options.d.ts +326 -0
- package/dist/typescript/lib/pipelines/stage_options.d.ts.map +1 -0
- package/dist/typescript/lib/pipelines/types.d.ts +10 -0
- package/dist/typescript/lib/pipelines/types.d.ts.map +1 -0
- package/dist/typescript/lib/types/firestore.d.ts +263 -0
- package/dist/typescript/lib/types/firestore.d.ts.map +1 -0
- package/dist/typescript/lib/types/internal.d.ts +483 -0
- package/dist/typescript/lib/types/internal.d.ts.map +1 -0
- package/dist/typescript/lib/types/namespaced.d.ts +2285 -0
- package/dist/typescript/lib/types/namespaced.d.ts.map +1 -0
- package/dist/typescript/lib/utils/index.d.ts +15 -0
- package/dist/typescript/lib/utils/index.d.ts.map +1 -0
- package/dist/typescript/lib/utils/serialize.d.ts +17 -0
- package/dist/typescript/lib/utils/serialize.d.ts.map +1 -0
- package/dist/typescript/lib/utils/typemap.d.ts +3 -0
- package/dist/typescript/lib/utils/typemap.d.ts.map +1 -0
- package/dist/typescript/lib/version.d.ts +2 -0
- package/dist/typescript/lib/version.d.ts.map +1 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.android.d.ts +3 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.android.d.ts.map +1 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.d.ts +75 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.d.ts.map +1 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.ios.d.ts +3 -0
- package/dist/typescript/lib/web/RNFBFirestoreModule.ios.d.ts.map +1 -0
- package/dist/typescript/lib/web/convert.d.ts +14 -0
- package/dist/typescript/lib/web/convert.d.ts.map +1 -0
- package/dist/typescript/lib/web/pipelines/pipeline.d.ts +4 -0
- package/dist/typescript/lib/web/pipelines/pipeline.d.ts.map +1 -0
- package/dist/typescript/lib/web/pipelines/pipeline_bridge_factory.d.ts +5 -0
- package/dist/typescript/lib/web/pipelines/pipeline_bridge_factory.d.ts.map +1 -0
- package/dist/typescript/lib/web/pipelines/pipeline_node_builder.d.ts +5 -0
- package/dist/typescript/lib/web/pipelines/pipeline_node_builder.d.ts.map +1 -0
- package/dist/typescript/lib/web/pipelines/pipeline_parser.d.ts +3 -0
- package/dist/typescript/lib/web/pipelines/pipeline_parser.d.ts.map +1 -0
- package/dist/typescript/lib/web/pipelines/pipeline_snapshot_serializer.d.ts +4 -0
- package/dist/typescript/lib/web/pipelines/pipeline_snapshot_serializer.d.ts.map +1 -0
- package/dist/typescript/lib/web/query.d.ts +23 -0
- package/dist/typescript/lib/web/query.d.ts.map +1 -0
- package/dist/typescript/package.json +1 -0
- package/ios/RNFBFirestore/RNFBFirestoreCollectionModule.m +52 -2
- package/ios/RNFBFirestore/RNFBFirestorePipelineBridgeFactory.swift +384 -0
- package/ios/RNFBFirestore/RNFBFirestorePipelineCallHandler.swift +86 -0
- package/ios/RNFBFirestore/RNFBFirestorePipelineNodeBuilder.swift +1500 -0
- package/ios/RNFBFirestore/RNFBFirestorePipelineParser.swift +1352 -0
- package/ios/RNFBFirestore/RNFBFirestorePipelineSnapshotSerializer.swift +98 -0
- package/lib/{FirestoreFieldPath.js → FieldPath.ts} +10 -12
- package/lib/{FirestoreFieldValue.js → FieldValue.ts} +22 -19
- package/lib/FirestoreAggregate.ts +124 -0
- package/lib/FirestoreBlob.ts +73 -0
- package/lib/FirestoreCollectionReference.ts +99 -0
- package/lib/FirestoreDocumentChange.ts +71 -0
- package/lib/FirestoreDocumentReference.ts +310 -0
- package/lib/FirestoreDocumentSnapshot.ts +149 -0
- package/lib/FirestoreFilter.ts +232 -0
- package/lib/{FirestoreGeoPoint.js → FirestoreGeoPoint.ts} +48 -8
- package/lib/FirestorePath.ts +54 -0
- package/lib/FirestorePersistentCacheIndexManager.ts +46 -0
- package/lib/{FirestoreQuery.js → FirestoreQuery.ts} +208 -100
- package/lib/FirestoreQueryModifiers.ts +411 -0
- package/lib/{FirestoreQuerySnapshot.js → FirestoreQuerySnapshot.ts} +61 -32
- package/lib/{FirestoreSnapshotMetadata.js → FirestoreSnapshotMetadata.ts} +8 -6
- package/lib/{FirestoreStatics.js → FirestoreStatics.ts} +18 -11
- package/lib/FirestoreTimestamp.ts +161 -0
- package/lib/{FirestoreTransaction.js → FirestoreTransaction.ts} +64 -27
- package/lib/{FirestoreTransactionHandler.js → FirestoreTransactionHandler.ts} +54 -75
- package/lib/{FirestoreVectorValue.js → FirestoreVectorValue.ts} +36 -15
- package/lib/{FirestoreWriteBatch.js → FirestoreWriteBatch.ts} +45 -21
- package/lib/LoadBundleTask.ts +85 -0
- package/lib/index.ts +71 -0
- package/lib/modular/Bytes.ts +81 -0
- package/lib/modular/FieldPath.ts +24 -0
- package/lib/modular/FieldValue.ts +40 -0
- package/lib/modular/GeoPoint.ts +20 -0
- package/lib/modular/Timestamp.ts +20 -0
- package/lib/modular/VectorValue.ts +24 -0
- package/lib/modular/query.ts +368 -0
- package/lib/modular/snapshot.ts +137 -0
- package/lib/modular.ts +552 -0
- package/lib/{index.js → namespaced.ts} +170 -80
- package/lib/pipelines/expressions.ts +2321 -0
- package/lib/pipelines/index.ts +203 -0
- package/lib/pipelines/pipeline-result.ts +78 -0
- package/lib/pipelines/pipeline-source.ts +83 -0
- package/lib/pipelines/pipeline.ts +99 -0
- package/lib/pipelines/pipeline_impl.ts +46 -0
- package/lib/pipelines/pipeline_options.ts +32 -0
- package/lib/pipelines/pipeline_runtime.ts +863 -0
- package/lib/pipelines/pipeline_support.ts +134 -0
- package/lib/pipelines/pipeline_validate.ts +242 -0
- package/lib/pipelines/stage_options.ts +376 -0
- package/lib/pipelines/types.ts +26 -0
- package/lib/types/firestore.ts +477 -0
- package/lib/types/internal.ts +747 -0
- package/lib/{index.d.ts → types/namespaced.ts} +280 -79
- package/lib/utils/index.ts +244 -0
- package/lib/utils/serialize.ts +314 -0
- package/lib/utils/typemap.ts +65 -0
- package/lib/version.ts +2 -0
- package/lib/web/{RNFBFirestoreModule.js → RNFBFirestoreModule.ts} +222 -234
- package/lib/web/convert.ts +287 -0
- package/lib/web/pipelines/pipeline.ts +47 -0
- package/lib/web/pipelines/pipeline_bridge_factory.ts +377 -0
- package/lib/web/pipelines/pipeline_node_builder.ts +413 -0
- package/lib/web/pipelines/pipeline_parser.ts +23 -0
- package/lib/web/pipelines/pipeline_snapshot_serializer.ts +133 -0
- package/lib/web/query.ts +150 -0
- package/package.json +46 -7
- package/tsconfig.json +35 -0
- package/lib/FirestoreBlob.js +0 -107
- package/lib/FirestoreCollectionReference.js +0 -70
- package/lib/FirestoreDocumentReference.js +0 -222
- package/lib/FirestoreDocumentSnapshot.js +0 -132
- package/lib/FirestoreFilter.js +0 -156
- package/lib/modular/Bytes.d.ts +0 -11
- package/lib/modular/Bytes.js +0 -62
- package/lib/modular/FieldPath.d.ts +0 -20
- package/lib/modular/FieldPath.js +0 -7
- package/lib/modular/FieldValue.d.ts +0 -67
- package/lib/modular/FieldValue.js +0 -41
- package/lib/modular/GeoPoint.d.ts +0 -17
- package/lib/modular/GeoPoint.js +0 -3
- package/lib/modular/Timestamp.d.ts +0 -85
- package/lib/modular/Timestamp.js +0 -3
- package/lib/modular/VectorValue.d.ts +0 -30
- package/lib/modular/VectorValue.js +0 -11
- package/lib/modular/index.d.ts +0 -788
- package/lib/modular/index.js +0 -410
- package/lib/modular/query.d.ts +0 -370
- package/lib/modular/query.js +0 -233
- package/lib/modular/snapshot.d.ts +0 -256
- package/lib/modular/snapshot.js +0 -33
- package/lib/modular/utils/observer.js +0 -16
- package/lib/version.js +0 -2
- package/lib/web/query.js +0 -112
- /package/lib/web/{RNFBFirestoreModule.android.js → RNFBFirestoreModule.android.ts} +0 -0
- /package/lib/web/{RNFBFirestoreModule.ios.js → RNFBFirestoreModule.ios.ts} +0 -0
|
@@ -16,18 +16,31 @@
|
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
18
|
import { isObject } from '@react-native-firebase/app/dist/module/common';
|
|
19
|
-
import
|
|
20
|
-
import { parseSetOptions, parseUpdateArgs } from './utils';
|
|
19
|
+
import DocumentReference from './FirestoreDocumentReference';
|
|
20
|
+
import { parseSetOptions, parseUpdateArgs, applyFirestoreDataConverter } from './utils';
|
|
21
21
|
import { buildNativeMap } from './utils/serialize';
|
|
22
|
+
import type { FirestoreInternal } from './types/internal';
|
|
23
|
+
import type { SetOptions } from './types/firestore';
|
|
24
|
+
|
|
25
|
+
export interface BatchWrite {
|
|
26
|
+
path: string;
|
|
27
|
+
type: 'DELETE' | 'SET' | 'UPDATE';
|
|
28
|
+
data?: Record<string, unknown>;
|
|
29
|
+
options?: Record<string, unknown>;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export default class WriteBatch {
|
|
33
|
+
_firestore: FirestoreInternal;
|
|
34
|
+
_writes: BatchWrite[];
|
|
35
|
+
_committed: boolean;
|
|
22
36
|
|
|
23
|
-
|
|
24
|
-
constructor(firestore) {
|
|
37
|
+
constructor(firestore: FirestoreInternal) {
|
|
25
38
|
this._firestore = firestore;
|
|
26
39
|
this._writes = [];
|
|
27
40
|
this._committed = false;
|
|
28
41
|
}
|
|
29
42
|
|
|
30
|
-
_verifyNotCommitted(method) {
|
|
43
|
+
_verifyNotCommitted(method: string): void {
|
|
31
44
|
if (this._committed) {
|
|
32
45
|
throw new Error(
|
|
33
46
|
`firebase.firestore.batch().${method}(*) A write batch can no longer be used after commit() has been called.`,
|
|
@@ -35,18 +48,20 @@ export default class FirestoreWriteBatch {
|
|
|
35
48
|
}
|
|
36
49
|
}
|
|
37
50
|
|
|
38
|
-
commit() {
|
|
51
|
+
commit(): Promise<void> {
|
|
39
52
|
this._verifyNotCommitted('commit');
|
|
40
53
|
this._committed = true;
|
|
41
54
|
if (this._writes.length === 0) {
|
|
42
55
|
return Promise.resolve();
|
|
43
56
|
}
|
|
44
|
-
return this._firestore.native.documentBatch(
|
|
57
|
+
return this._firestore.native.documentBatch(
|
|
58
|
+
this._writes as unknown as Array<Record<string, unknown>>,
|
|
59
|
+
);
|
|
45
60
|
}
|
|
46
61
|
|
|
47
|
-
delete(documentRef) {
|
|
62
|
+
delete(documentRef: DocumentReference): this {
|
|
48
63
|
this._verifyNotCommitted('delete');
|
|
49
|
-
if (!(documentRef instanceof
|
|
64
|
+
if (!(documentRef instanceof DocumentReference)) {
|
|
50
65
|
throw new Error(
|
|
51
66
|
"firebase.firestore.batch().delete(*) 'documentRef' expected instance of a DocumentReference.",
|
|
52
67
|
);
|
|
@@ -66,9 +81,9 @@ export default class FirestoreWriteBatch {
|
|
|
66
81
|
return this;
|
|
67
82
|
}
|
|
68
83
|
|
|
69
|
-
set(documentRef, data, options) {
|
|
84
|
+
set(documentRef: DocumentReference, data: Record<string, unknown>, options?: SetOptions): this {
|
|
70
85
|
this._verifyNotCommitted('set');
|
|
71
|
-
if (!(documentRef instanceof
|
|
86
|
+
if (!(documentRef instanceof DocumentReference)) {
|
|
72
87
|
throw new Error(
|
|
73
88
|
"firebase.firestore.batch().set(*) 'documentRef' expected instance of a DocumentReference.",
|
|
74
89
|
);
|
|
@@ -80,30 +95,39 @@ export default class FirestoreWriteBatch {
|
|
|
80
95
|
);
|
|
81
96
|
}
|
|
82
97
|
|
|
83
|
-
|
|
84
|
-
|
|
98
|
+
let setOptions: Record<string, unknown>;
|
|
99
|
+
try {
|
|
100
|
+
setOptions = parseSetOptions(options);
|
|
101
|
+
} catch (e) {
|
|
102
|
+
throw new Error(`firebase.firestore().batch().set(_, *) ${(e as Error).message}.`);
|
|
85
103
|
}
|
|
86
104
|
|
|
87
|
-
let
|
|
105
|
+
let converted: Record<string, unknown> | unknown = data;
|
|
88
106
|
try {
|
|
89
|
-
|
|
107
|
+
converted = applyFirestoreDataConverter(data, documentRef.converter, setOptions);
|
|
90
108
|
} catch (e) {
|
|
91
|
-
throw new Error(
|
|
109
|
+
throw new Error(
|
|
110
|
+
`firebase.firestore().batch().set(_, *) 'withConverter.toFirestore' threw an error: ${(e as Error).message}.`,
|
|
111
|
+
);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
if (!isObject(converted)) {
|
|
115
|
+
throw new Error("firebase.firestore.batch().set(_, *) 'data' must be an object.");
|
|
92
116
|
}
|
|
93
117
|
|
|
94
118
|
this._writes.push({
|
|
95
119
|
path: documentRef.path,
|
|
96
120
|
type: 'SET',
|
|
97
|
-
data: buildNativeMap(
|
|
121
|
+
data: buildNativeMap(converted, this._firestore._settings.ignoreUndefinedProperties),
|
|
98
122
|
options: setOptions,
|
|
99
123
|
});
|
|
100
124
|
|
|
101
125
|
return this;
|
|
102
126
|
}
|
|
103
127
|
|
|
104
|
-
update(documentRef, ...args) {
|
|
128
|
+
update(documentRef: DocumentReference, ...args: unknown[]): this {
|
|
105
129
|
this._verifyNotCommitted('update');
|
|
106
|
-
if (!(documentRef instanceof
|
|
130
|
+
if (!(documentRef instanceof DocumentReference)) {
|
|
107
131
|
throw new Error(
|
|
108
132
|
"firebase.firestore.batch().update(*) 'documentRef' expected instance of a DocumentReference.",
|
|
109
133
|
);
|
|
@@ -121,11 +145,11 @@ export default class FirestoreWriteBatch {
|
|
|
121
145
|
);
|
|
122
146
|
}
|
|
123
147
|
|
|
124
|
-
let data
|
|
148
|
+
let data: Record<string, unknown>;
|
|
125
149
|
try {
|
|
126
150
|
data = parseUpdateArgs(args);
|
|
127
151
|
} catch (e) {
|
|
128
|
-
throw new Error(`firebase.firestore
|
|
152
|
+
throw new Error(`firebase.firestore.batch().update(_, *) ${(e as Error).message}`);
|
|
129
153
|
}
|
|
130
154
|
|
|
131
155
|
this._writes.push({
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import type { LoadBundleTaskProgress } from './types/firestore';
|
|
19
|
+
|
|
20
|
+
type ProgressObserver = {
|
|
21
|
+
next?: (progress: LoadBundleTaskProgress) => unknown;
|
|
22
|
+
error?: (err: Error) => unknown;
|
|
23
|
+
complete?: () => void;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export class LoadBundleTask implements PromiseLike<LoadBundleTaskProgress> {
|
|
27
|
+
private _progressObserver: ProgressObserver = {};
|
|
28
|
+
private _completionPromise: Promise<LoadBundleTaskProgress>;
|
|
29
|
+
private _resolve?: (progress: LoadBundleTaskProgress) => void;
|
|
30
|
+
private _reject?: (error: Error) => void;
|
|
31
|
+
private _lastProgress: LoadBundleTaskProgress = {
|
|
32
|
+
taskState: 'Running',
|
|
33
|
+
totalBytes: 0,
|
|
34
|
+
totalDocuments: 0,
|
|
35
|
+
bytesLoaded: 0,
|
|
36
|
+
documentsLoaded: 0,
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
constructor() {
|
|
40
|
+
this._completionPromise = new Promise((resolve, reject) => {
|
|
41
|
+
this._resolve = resolve;
|
|
42
|
+
this._reject = reject;
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
onProgress(
|
|
47
|
+
next?: (progress: LoadBundleTaskProgress) => unknown,
|
|
48
|
+
error?: (err: Error) => unknown,
|
|
49
|
+
complete?: () => void,
|
|
50
|
+
): void {
|
|
51
|
+
this._progressObserver = { next, error, complete };
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
catch<R>(onRejected: (a: Error) => R | PromiseLike<R>): Promise<R | LoadBundleTaskProgress> {
|
|
55
|
+
return this._completionPromise.catch(onRejected);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
then<T, R>(
|
|
59
|
+
onFulfilled?: (a: LoadBundleTaskProgress) => T | PromiseLike<T>,
|
|
60
|
+
onRejected?: (a: Error) => R | PromiseLike<R>,
|
|
61
|
+
): Promise<T | R> {
|
|
62
|
+
return this._completionPromise.then(onFulfilled, onRejected);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
_completeWith(progress: LoadBundleTaskProgress): void {
|
|
66
|
+
this._updateProgress(progress);
|
|
67
|
+
this._progressObserver.complete?.();
|
|
68
|
+
this._resolve?.(progress);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
_failWith(error: Error): void {
|
|
72
|
+
this._lastProgress = { ...this._lastProgress, taskState: 'Error' };
|
|
73
|
+
this._progressObserver.next?.(this._lastProgress);
|
|
74
|
+
this._progressObserver.error?.(error);
|
|
75
|
+
this._reject?.(error);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
_updateProgress(progress: LoadBundleTaskProgress): void {
|
|
79
|
+
if (this._lastProgress.taskState !== 'Running') {
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
this._lastProgress = progress;
|
|
83
|
+
this._progressObserver.next?.(progress);
|
|
84
|
+
}
|
|
85
|
+
}
|
package/lib/index.ts
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
// Export modular API functions
|
|
19
|
+
export * from './modular';
|
|
20
|
+
|
|
21
|
+
// Export modular/public type helpers.
|
|
22
|
+
// DocumentSnapshot, LoadBundleTask, QuerySnapshot, SnapshotMetadata, Transaction, WriteBatch
|
|
23
|
+
// are excluded here because they are already exported as values from './modular'.
|
|
24
|
+
export type {
|
|
25
|
+
FirebaseApp,
|
|
26
|
+
Firestore,
|
|
27
|
+
LogLevel,
|
|
28
|
+
ExperimentalLongPollingOptions,
|
|
29
|
+
PersistenceSettings,
|
|
30
|
+
MemoryLocalCache,
|
|
31
|
+
PersistentLocalCache,
|
|
32
|
+
FirestoreLocalCache,
|
|
33
|
+
FirestoreSettings,
|
|
34
|
+
AggregateType,
|
|
35
|
+
AggregateFieldType,
|
|
36
|
+
AggregateSpec,
|
|
37
|
+
AggregateSpecData,
|
|
38
|
+
EmulatorMockTokenOptions,
|
|
39
|
+
TaskState,
|
|
40
|
+
LoadBundleTaskProgress,
|
|
41
|
+
SetOptions,
|
|
42
|
+
WhereFilterOp,
|
|
43
|
+
OrderByDirection,
|
|
44
|
+
QueryConstraintType,
|
|
45
|
+
SnapshotListenOptions,
|
|
46
|
+
SnapshotOptions,
|
|
47
|
+
DocumentChangeType,
|
|
48
|
+
FirestoreError,
|
|
49
|
+
Unsubscribe,
|
|
50
|
+
DocumentChange,
|
|
51
|
+
Primitive,
|
|
52
|
+
DocumentData,
|
|
53
|
+
PartialWithFieldValue,
|
|
54
|
+
UnionToIntersection,
|
|
55
|
+
AddPrefixToKeys,
|
|
56
|
+
ChildUpdateFields,
|
|
57
|
+
NestedUpdateFields,
|
|
58
|
+
UpdateData,
|
|
59
|
+
WithFieldValue,
|
|
60
|
+
FirestoreDataConverter,
|
|
61
|
+
Query,
|
|
62
|
+
CollectionReference,
|
|
63
|
+
DocumentReference,
|
|
64
|
+
QueryDocumentSnapshot,
|
|
65
|
+
} from './types/firestore';
|
|
66
|
+
|
|
67
|
+
// Export namespaced API
|
|
68
|
+
export type { FirebaseFirestoreTypes } from './types/namespaced';
|
|
69
|
+
|
|
70
|
+
export * from './namespaced';
|
|
71
|
+
export { default } from './namespaced';
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import Blob from '../FirestoreBlob';
|
|
19
|
+
import type { FirestoreBlobInternal } from '../types/internal';
|
|
20
|
+
|
|
21
|
+
export class Bytes extends Blob {
|
|
22
|
+
constructor(blob: FirestoreBlobInternal) {
|
|
23
|
+
super(true);
|
|
24
|
+
// Binary string was already parsed and created; avoid reparsing.
|
|
25
|
+
(this as FirestoreBlobInternal)._binaryString = blob._binaryString;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
static fromBase64String(base64: string): Bytes {
|
|
29
|
+
try {
|
|
30
|
+
return new Bytes(Blob.fromBase64String(base64) as FirestoreBlobInternal);
|
|
31
|
+
} catch (error) {
|
|
32
|
+
throw new Error(`Failed to construct data from Base64 string: ${error}`);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
static fromUint8Array(array: Uint8Array): Bytes {
|
|
37
|
+
return new Bytes(Blob.fromUint8Array(array) as FirestoreBlobInternal);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
toBase64(): string {
|
|
41
|
+
return super.toBase64();
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
toUint8Array(): Uint8Array {
|
|
45
|
+
return super.toUint8Array();
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
toString(): string {
|
|
49
|
+
return `Bytes(base64: ${this.toBase64()})`;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
isEqual(other: Bytes): boolean {
|
|
53
|
+
return super.isEqual(other);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
static _jsonSchemaVersion: string = 'firestore/bytes/1.0';
|
|
57
|
+
static _jsonSchema = {
|
|
58
|
+
type: Bytes._jsonSchemaVersion,
|
|
59
|
+
bytes: 'string',
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
toJSON(): { type: string; bytes: string } {
|
|
63
|
+
return {
|
|
64
|
+
type: Bytes._jsonSchemaVersion,
|
|
65
|
+
bytes: this.toBase64(),
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
static fromJSON(json: object): Bytes {
|
|
70
|
+
if (
|
|
71
|
+
json &&
|
|
72
|
+
typeof (json as { type?: unknown }).type === 'string' &&
|
|
73
|
+
(json as { type?: string }).type === Bytes._jsonSchemaVersion &&
|
|
74
|
+
typeof (json as { bytes?: unknown }).bytes === 'string'
|
|
75
|
+
) {
|
|
76
|
+
return Bytes.fromBase64String((json as { bytes: string }).bytes);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
throw new Error('Unexpected error creating Bytes from JSON.');
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import FieldPath, { DOCUMENT_ID } from '../FieldPath';
|
|
19
|
+
|
|
20
|
+
export { FieldPath };
|
|
21
|
+
|
|
22
|
+
export function documentId(): FieldPath {
|
|
23
|
+
return DOCUMENT_ID;
|
|
24
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import FieldValue from '../FieldValue';
|
|
19
|
+
|
|
20
|
+
export { FieldValue };
|
|
21
|
+
|
|
22
|
+
export function deleteField(): FieldValue {
|
|
23
|
+
return FieldValue.delete();
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export function serverTimestamp(): FieldValue {
|
|
27
|
+
return FieldValue.serverTimestamp();
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export function arrayUnion(...elements: unknown[]): FieldValue {
|
|
31
|
+
return FieldValue.arrayUnion(...elements);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export function arrayRemove(...elements: unknown[]): FieldValue {
|
|
35
|
+
return FieldValue.arrayRemove(...elements);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function increment(n: number): FieldValue {
|
|
39
|
+
return FieldValue.increment(n);
|
|
40
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import GeoPoint from '../FirestoreGeoPoint';
|
|
19
|
+
|
|
20
|
+
export { GeoPoint };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import Timestamp from '../FirestoreTimestamp';
|
|
19
|
+
|
|
20
|
+
export { Timestamp };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import VectorValue from '../FirestoreVectorValue';
|
|
19
|
+
|
|
20
|
+
export { VectorValue };
|
|
21
|
+
|
|
22
|
+
export function vector(values?: number[]): VectorValue {
|
|
23
|
+
return new VectorValue(values);
|
|
24
|
+
}
|