Data types

Most of the basic types, as well as some more complex types, are defined in the core.data_types.schema.yml file:

# Basic scalar data types from typed data.
boolean:
  label: 'Boolean'
  class: '\Drupal\Core\TypedData\Plugin\DataType\Boolean'
email:
  label: 'Email'
  class: '\Drupal\Core\TypedData\Plugin\DataType\Email'
integer:
  label: 'Integer'
  class: '\Drupal\Core\TypedData\Plugin\DataType\Integer'
float:
  label: 'Float'
  class: '\Drupal\Core\TypedData\Plugin\DataType\Float'
string:
  label: 'String'
  class: '\Drupal\Core\TypedData\Plugin\DataType\String'
uri:
  label: 'Uri'
  class: '\Drupal\Core\TypedData\Plugin\DataType\Uri'

These types have a direct mapping to their Typed Data API counterparts. The Typed Data API has been created to provide developers ...

Get Drupal 8 Configuration Management now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.