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).
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-11 UTC."],[],[],null,["# FirebaseFirestore Framework Reference\n\nFieldPath\n=========\n\n class FieldPath : NSObject, NSCopying, @unchecked Sendable\n\nA `FieldPath` refers to a field in a document. The path may consist of a single field name\n(referring to a top level field in the document), or a list of field names (referring to a nested\nfield in the document).\n- `\n ``\n ``\n `\n\n ### [init(_:)](#/c:objc(cs)FIRFieldPath(im)initWithFields:)\n\n `\n ` \n Creates a `FieldPath` from the provided field names. If more than one field name is provided, the\n path will point to a nested field in a document. \n\n #### Declaration\n\n Swift \n\n init(_ fieldNames: [String])\n\n #### Parameters\n\n |--------------------|------------------------|\n | ` `*fieldNames*` ` | A list of field names. |\n\n #### Return Value\n\n A `FieldPath` that points to a field location in a document.\n- `\n ``\n ``\n `\n\n ### [documentID()](#/c:objc(cs)FIRFieldPath(cm)documentID)\n\n `\n ` \n A special sentinel `FieldPath` to refer to the ID of a document. It can be used in queries to\n sort or filter by the document ID. \n\n #### Declaration\n\n Swift \n\n class func documentID() -\u003e Self"]]