Stay organized with collections
Save and categorize content based on your preferences.
Constructors
constructor
- new FieldPath
(
...
fieldNames
:
string
[]
)
:
FieldPath
-
Parameters
-
Rest ...fieldNames: string[]
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2022-07-27 UTC.
[null,null,["Last updated 2022-07-27 UTC."],[],[],null,["- [firebase](/docs/reference/node/firebase).\n- [firestore](/docs/reference/node/firebase.firestore).\n- FieldPath \nA FieldPath refers to a field in a document. The path may consist of a\nsingle field name (referring to a top-level field in the document), or a\nlist of field names (referring to a nested field in the document).\n\nCreate a FieldPath by providing field names. If more than one field\nname is provided, the path will point to a nested field in a document.\n\nIndex\n\nConstructors\n\n- [constructor](/docs/reference/node/firebase.firestore.FieldPath#constructor)\n\nMethods\n\n- [isEqual](/docs/reference/node/firebase.firestore.FieldPath#isequal)\n- [documentId](/docs/reference/node/firebase.firestore.FieldPath#documentid)\n\nConstructors\n\nconstructor\n\n- new FieldPath ( ... fieldNames : string \\[\\] ) : [FieldPath](/docs/reference/node/firebase.firestore.FieldPath)\n- Creates a FieldPath from the provided field names. If more than one field\n name is provided, the path will point to a nested field in a document.\n\n Parameters\n -\n\n Rest ...fieldNames: string\\[\\] \n A list of field names.\n\n Returns [FieldPath](/docs/reference/node/firebase.firestore.FieldPath)\n\nMethods\n\nisEqual\n\n- isEqual ( other : [FieldPath](/docs/reference/node/firebase.firestore.FieldPath) ) : boolean\n- Returns true if this `FieldPath` is equal to the provided one.\n\n Parameters\n -\n\n other: [FieldPath](/docs/reference/node/firebase.firestore.FieldPath) \n The `FieldPath` to compare against.\n\n Returns boolean\n\n true if this `FieldPath` is equal to the provided one.\n\nStatic documentId\n\n- documentId ( ) : [FieldPath](/docs/reference/node/firebase.firestore.FieldPath)\n- Returns a special sentinel `FieldPath` to refer to the ID of a document.\n It can be used in queries to sort or filter by the document ID.\n\nReturns [FieldPath](/docs/reference/node/firebase.firestore.FieldPath)"]]
A FieldPath refers to a field in a document. The path may consist of a single field name (referring to a top-level field in the document), or a list of field names (referring to a nested field in the document).
Create a FieldPath by providing field names. If more than one field name is provided, the path will point to a nested field in a document.