diff --git a/components/config/definition.rst b/components/config/definition.rst index a6a6f908fa7..a83757dff68 100644 --- a/components/config/definition.rst +++ b/components/config/definition.rst @@ -425,9 +425,34 @@ All options can be documented using the :method:`Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition::info` method. +.. code-block:: php + + $rootNode + ->children() + ->integerNode('entries_per_page') + ->info('This value is only used for the search results page.') + ->defaultValue(25) + ->end() + ->end() + ; + The info will be printed as a comment when dumping the configuration tree with the ``config:dump-reference`` command. +In YAML you may have: + +.. code-block:: yaml + + # This value is only used for the search results page. + entries_per_page: 25 + +and in XML: + +.. code-block:: xml + + + + Optional Sections -----------------