From 316bec5df9f9418a3c8d882b50da5460999bfc99 Mon Sep 17 00:00:00 2001 From: raceychan Date: Fri, 3 Jan 2025 18:18:39 +0800 Subject: [PATCH] chores: readme --- README.md | 42 +++++++++++++++++------------------------- 1 file changed, 17 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index 0d70cd1..2be9aa7 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,15 @@ To view viusal dependency graph, install `graphviz` pip install ididi[graphviz] ``` +## Features + +- No / minial changes to your existing code +- Smart injection based on type hints with strong support to `typing` module. +- Advanced scope support +- Formated and detail-rich error messages +- Highly performant, on part with nodejs and go + + ## Usage ### Quick Start @@ -57,16 +66,6 @@ await main(CreateUser(name='user')) This would create a `UnitOfWork` instance, with a opened sqlalchemy.AsyncConnection from `conn_factory` when `main` is called. The connection will be closed when `main` is finished. -## Features - -- requires no / minial changes to your existing code -- smart injection based on type hints, strong support to typing, including `typing.Union`, `typing.Annotated`, etc. -- advanced resource lifetime management with scope, name scope, context scope, etc. -- sync and async dependency resolution -- resolving functions, classes, factory functions of classes, etc. -- formated and detail-rich error messages -- highly performant, on part with nodejs and go - ### Dependency factory assign which factory method to use with `ididi.use` @@ -198,26 +197,19 @@ async with dg.scope(app_name) as app_scope: For any functions called within the request_scope, you can get the most recent scope with `dg.use_scope()`, or its parent scopes, i.e. `dg.use_scope(app_name)` to get app_scope. -### Tutorial - -check out documentation for more details - -### Usage of factory - -check out documentation for more details -### Visualize the dependency graph(beta) +### More -check out documentation for more details +For more detailed information, check out [Documentation](https://raceychan.github.io/ididi) -### Circular Dependency Detection +- Tutorial -check out documentation for more details +- Usage of factory -### Lazy Dependency(Beta) +- Visualize the dependency graph(beta) -check out documentation for more details +- Circular Dependency Detection -### Error context +- Lazy Dependency(Beta) -check out documentation for more details \ No newline at end of file +- Error context