You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: contributing/documentation/overview.rst
+16-8Lines changed: 16 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -71,15 +71,21 @@ GitHub covers the topic of `pull requests`_ in detail.
71
71
Standards
72
72
---------
73
73
74
-
In order to help the reader as much as possible and to create code examples that looks and feels familiar, you should follow these rules:
75
-
76
-
* The code follows the Coding Standards, the `Symfony Coding Standards`_ as well as the `Twig Coding Standards`_;
77
-
* When we fold one or more lines of code, we place `...` in a comment at the point of the fold. These comments are: `// ...` (php), `# ...` (yaml/bash), `{# ... #}` (twig), `<!-- ... -->` (xml/html), `; ...` (ini), `...` (text);
78
-
* When we fold a part of a line, e.g. a variable value, we put `...` (without comment) at the place of the fold;
74
+
In order to help the reader as much as possible and to create code examples that
75
+
looks and feels familiar, you should follow these rules:
76
+
77
+
* The code follows the Coding Standards, the `Symfony Coding Standards`_ as well
78
+
as the `Twig Coding Standards`_;
79
+
* When we fold one or more lines of code, we place `...` in a comment at the point
80
+
of the fold. These comments are: `// ...` (php), `# ...` (yaml/bash), `{# ... #}` (twig),
* When we fold a part of a line, e.g. a variable value, we put `...` (without comment)
83
+
at the place of the fold;
79
84
* Description about the fold: (optional)
80
85
If we fold some lines: The description can be placed after the `...`
81
86
If we fold a part of a line: The description can be placed before the line;
82
-
* If usefull, a codeblock begins with a comment with the filename. After this comment should not be a blank line, except if the next line is a comment too;
87
+
* If usefull, a codeblock begins with a comment with the filename. After this comment
88
+
should not be a blank line, except if the next line is a comment too;
83
89
* You should put a `$` in front of every bash line;
84
90
* We prefer the `::` shorthand over `.. code-block:: php` to begin a PHP code block.
85
91
@@ -97,8 +103,10 @@ An example::
97
103
}
98
104
99
105
.. note::
100
-
* In Yaml you should to put a space after `{` and before `}` (e.g. `{ _controller: ... }`), but this should not be done in Twig (e.g. `{'hello' : 'value'}`).
101
-
* An array item is a part of a line, not a complete line. So you should not use `// ...` but `...,` (the comma because of the Coding Standards):
106
+
* In Yaml you should to put a space after `{` and before `}` (e.g. `{ _controller: ... }`),
107
+
but this should not be done in Twig (e.g. `{'hello' : 'value'}`).
108
+
* An array item is a part of a line, not a complete line. So you should not use `// ...`
109
+
but `...,` (the comma because of the Coding Standards):
0 commit comments