Class VectorValue (7.6.0)

Represent a vector type in Firestore documents. Create an instance with FieldValue.vector().

VectorValue

Package

@google-cloud/firestore

Remarks

The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the VectorValue class.

Methods

isEqual(other)

isEqual(other: VectorValue): boolean;

Returns true if the two VectorValue has the same raw number arrays, returns false otherwise.

Parameter
Name Description
other VectorValue
Returns
Type Description
boolean

toArray()

toArray(): number[];

Returns a copy of the raw number array form of the vector.

Returns
Type Description
number[]