python-dependency-injector/docs/providers/list.rst
Roman Mogylatov c4b33749d2
Providers docs update (#289)
* Update callable provider docs

* Update coroutine provider docs

* Edit object docs

* Edit list provider docs

* Edit configuration provider docs

* Edit selector provider docs

* Fix mypy stub of the ``DeclarativeContainer`` to specify the ``__init__`` interface

* Edit Dependency provider docs
2020-09-01 21:39:23 -04:00

24 lines
642 B
ReStructuredText

List provider
-------------
.. meta::
:keywords: Python,DI,Dependency injection,IoC,Inversion of Control,List,Injection
:description: List provider helps to inject a list of the dependencies. This page demonstrates
how to use a List provider.
.. currentmodule:: dependency_injector.providers
:py:class:`List` provider provides a list of values.
.. literalinclude:: ../../examples/providers/list.py
:language: python
:lines: 3-
:emphasize-lines: 19-22
``List`` provider handles positional arguments the same way as a :ref:`factory-provider`.
.. note::
Keyword argument are not supported.
.. disqus::