Skip to content

Commit dc18917

Browse files
committed
Merge branch '7.0' into 7.1
* 7.0: [Console] [components] add information about the addRows method - table.rst
2 parents 42d965b + aa87669 commit dc18917

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

components/console/helpers/table.rst

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -449,3 +449,24 @@ This will display the following table in the terminal:
449449
| Love |
450450
| Symfony |
451451
+---------+
452+
453+
.. tip::
454+
455+
You can create multiple lines using the :method:`Symfony\\Component\\Console\\Helper\\Table::addRows` method::
456+
457+
// ...
458+
$table->addRows([
459+
['Hello', 'World'],
460+
['Love', 'Symfony'],
461+
]);
462+
$table->render();
463+
// ...
464+
465+
This will display:
466+
467+
.. code-block:: terminal
468+
469+
+-------+---------+
470+
| Hello | World |
471+
| Love | Symfony |
472+
+-------+---------+

0 commit comments

Comments
 (0)