- In our module's base directory, let's create a config directory with a schema subdirectory. In the subdirectory, create a file named mymodule.schema.yml that will hold your configuration entity's schema:
- In our mymodule.schema.yml, add a definition to mymodule.announcement.*: to provide our label and message storage:
# Schema for the configuration files of the Site Announcement. mymodule.announcement.*: type: config_entity label: 'Site announcement' mapping: id: type: string label: 'ID' label: type: label label: 'Label' message: type: text label: 'Text'
We will define the configuration entity's namespace as an announcement, ...