Use it for questions about rendering or modifying the HTML markup produced by a module/theme.
Drupal theming system allows a theme to have nearly complete control over the appearance of the site, which includes both the markup and the CSS used to style the markup. For this system to work, modules, instead of writing HTML markup directly, need to return render arrays, which are structured hierarchical arrays that include the data to be rendered into HTML (or XML or another output format), and options that affect the markup. Render arrays are ultimately rendered into HTML or other output formats by recursive calls to drupal_render(), traversing the depth of the render array hierarchy. At each level, the theme system is invoked to do the actual rendering. See the documentation of drupal_render()
and the Theme system and Render API topic for more information about render arrays and rendering.
Reference
- Theme system overview (Drupal 8)
- Default theme implementations (Drupal 7)