API Reference@grafana/data › FieldConfig

FieldConfig interface

Every property is optional

Plugins may extend this with additional properties. Something like series overrides

Signature

export interface FieldConfig<TOptions extends object = any> 

Import

import { FieldConfig } from '@grafana/data';

Properties

Property Type Description
color FieldColor
custom TOptions
decimals number | null
displayName string The display value for this field. This supports template variables blank is auto
displayNameFromDS string This can be used by data sources that return and explicit naming structure for values and labels When this property is configured, this value is used rather than the default naming strategy.
filterable boolean True if data source field supports ad-hoc filters
links DataLink[]
mappings ValueMapping[]
max number | null
min number | null
noValue string
nullValueMode NullValueMode
thresholds ThresholdsConfig
unit string

color property

Signature

color?: FieldColor;

custom property

Signature

custom?: TOptions;

decimals property

Signature

decimals?: number | null;

displayName property

The display value for this field. This supports template variables blank is auto

Signature

displayName?: string;

displayNameFromDS property

This can be used by data sources that return and explicit naming structure for values and labels When this property is configured, this value is used rather than the default naming strategy.

Signature

displayNameFromDS?: string;

filterable property

True if data source field supports ad-hoc filters

Signature

filterable?: boolean;

Signature

links?: DataLink[];

mappings property

Signature

mappings?: ValueMapping[];

max property

Signature

max?: number | null;

min property

Signature

min?: number | null;

noValue property

Signature

noValue?: string;

nullValueMode property

Signature

nullValueMode?: NullValueMode;

thresholds property

Signature

thresholds?: ThresholdsConfig;

unit property

Signature

unit?: string;