FieldInfo
require(["esri/support/FieldInfo"], function(FieldInfo) { /* code goes here */ });esri/support/FieldInfoThe FieldInfo class defines how a Field participates, or in some cases, does not participate, in a PopupTemplate.
- See also:
let fieldInfo = new FieldInfo({
  fieldName: 'PROMINENCE_ft',
  label: 'Prominence (feet)',
  //autocasts to FieldInfo.Format
  format: {
    places: 0,
    digitSeparator: true
  }
};Constructors
- new FieldInfo(properties)
- Parameter:properties ObjectoptionalSee the properties for a list of all the properties that may be passed into the constructor. 
Property Overview
| Name | Type | Summary | Class | |
|---|---|---|---|---|
| String | The name of the class.more details | more details | Accessor | |
| String | The field name as defined by the service or the  | more details | FieldInfo | |
| Format | Class which provides formatting options for numerical or date fields and how they should display within a popup.more details | more details | FieldInfo | |
| Boolean | A Boolean determining whether users can edit this field.more details | more details | FieldInfo | |
| String | A string containing the field alias.more details | more details | FieldInfo | |
| String | Used in a  | more details | FieldInfo | |
| String | A string determining what type of input box editors see when editing the field.more details | more details | FieldInfo | |
| String | A string providing an editing hint for editors of the field.more details | more details | FieldInfo | |
| Boolean | Indicates whether the field is visible in the popup window.more details | more details | FieldInfo | 
Property Details
- The name of the class. The declared class name is formatted as - esri.folder.className.
- fieldNameString
- The field name as defined by the service or the - nameof an Arcade expression. Arcade expression names are defined in the expressionInfos property. When referencing Arcade expressions, you must preface the name with- expression/, such as- expression/percent-total.
- formatFormat
- Class which provides formatting options for numerical or date fields and how they should display within a popup. 
- isEditableBoolean
- A Boolean determining whether users can edit this field. This is not applicable to Arcade expressions. - Default Value:false
 
- labelString
- A string containing the field alias. Not applicable to Arcade expressions as the title is used instead. 
- statisticTypeString
- Used in a - one:manyor- many:manyrelationship to compute the statistics on the field to show in the popup. If the property is present, must be one of the following values:- Possible Values: count | sum | min | max | avg | stddev | var 
- stringFieldOptionString
- A string determining what type of input box editors see when editing the field. Applies only to string fields. This is not applicable to Arcade expressions. If this property is present, it must be one of the following values: - Possible Values: rich-text | text-area | text-box - Default Value:text-box
 
- tooltipString
- A string providing an editing hint for editors of the field. This is not applicable to Arcade expressions. 
- visibleBoolean
- Indicates whether the field is visible in the popup window. - Default Value:true
 
Method Overview
| Name | Return Type | Summary | Class | |
|---|---|---|---|---|
| FieldInfo | Creates a deep clone of the FieldInfo class.more details | more details | FieldInfo | |
| * | Creates a new instance of this class and initializes it with values from a JSON object generated from a product in the ArcGIS platform.more details | more details | FieldInfo | |
| Object | Converts an instance of this class to its ArcGIS portal JSON representation.more details | more details | FieldInfo | 
Method Details
- clone(){FieldInfo}
- Creates a deep clone of the FieldInfo class. Returns:- Type - Description - FieldInfo - A deep clone of the FieldInfo instance. 
- fromJSON(json){*}static
- Creates a new instance of this class and initializes it with values from a JSON object generated from a product in the ArcGIS platform. The object passed into the input - jsonparameter often comes from a response to a query operation in the REST API or a toJSON() method from another ArcGIS product. See the Using fromJSON() topic in the Guide for details and examples of when and how to use this function.Parameter:json Object- A JSON representation of the instance in the ArcGIS format. See the ArcGIS REST API documentation for examples of the structure of various input JSON objects. Returns:- Type - Description - * - Returns a new instance of this class. 
- toJSON(){Object}
- Converts an instance of this class to its ArcGIS portal JSON representation. See the Using fromJSON() topic in the Guide for more information. Returns:- Type - Description - Object - The ArcGIS portal JSON representation of an instance of this class.