Each module contains a file called description.yaml. This contains information about the module.
This section of the site describes the schema of the description.yaml file.
Your description.yaml file will be read by the CMS at the following times:
If you edit your description.yaml file, you MUST increment your module's revision number up by one so that the CMS will read in the change. This happens the next time an administrator tries to log in or go to /admin.
In summary, the description file contains:
If your module extents another module, or needs a feature from another module in order to run, you should state that module's name as a dependency.
The CMS will not allow your module to be started unless all of the modules named as dependencies are also running.
When the CMS runs a module's code, it will always first look for modules that are depended upon, and run them first. For example, if module B depends on module A, A will be run first, and then B.
In the CMS, the module zenario_menu_vertical extends the code of the module zenario_menu, so zenario_menu_vertical lists zenario_menu as a dependency.
A different case would be where a module calls a public static function from another module. If the module relies on this function call to work, then this would be a dependency. However if the function call is optional, and is wrapped in an if statement using the inc() function, then this would not be a dependency as the calling module would not break if the module being called was not running.