2020-07-18 07:40:14 +03:00
Key features
------------
2016-03-31 00:40:49 +03:00
2016-04-11 23:16:46 +03:00
.. meta ::
2016-04-23 15:00:06 +03:00
:keywords: Python,DI,Dependency injection,IoC,Inversion of Control
2020-09-03 20:36:19 +03:00
:description: This article describes key features of the Dependency Injector
framework.
2016-04-11 23:16:46 +03:00
2020-09-03 20:36:19 +03:00
`` Dependency Injector `` is a dependency injection framework for Python. It takes the
responsibility of assembling your objects.
2016-03-31 00:40:49 +03:00
2020-09-03 20:36:19 +03:00
Key features of the `` Dependency Injector `` are:
- **Pythonic design** . Simple & explicit.
- **High performance** . Written in `` Cython `` .
- **Maturity and production readiness** . Downloaded over 200.000 times a month.
2016-03-31 00:40:49 +03:00
2020-08-11 05:29:25 +03:00
It stands on two principles:
2020-09-03 20:36:19 +03:00
- **Explicit is better than implicit (PEP20)** .
- **Do not do any magic to your code** .
2020-08-11 05:29:25 +03:00
2020-09-03 20:36:19 +03:00
How is the `` Dependency Injector `` different from the other frameworks?
2020-08-11 05:29:25 +03:00
- **No autowiring.** The framework does NOT do any autowiring / autoresolving of the dependencies. You need to specify everything explicitly. Because *"Explicit is better than implicit" (PEP20)* .
- **Does not pollute your code.** Your application does NOT know and does NOT depend on the framework. No `` @inject `` decorators, annotations, patching or any other magic tricks.
2020-09-03 20:36:19 +03:00
In addition `` Dependency Injector `` is:
2016-03-31 00:40:49 +03:00
2020-09-03 20:36:19 +03:00
- Tested.
- Documented.
- Supported.
- Semantically versioned.
- Distributed as pre-compiled wheels.
2016-03-31 00:40:49 +03:00
2020-09-03 20:36:19 +03:00
The power of the `` Dependency Injector `` is in its straightforwardness. It is a simple tool for
the powerful concept.
2017-02-28 23:00:08 +03:00
.. disqus ::