From 4cb3884e24b3cba3347ff93475bbabd6fe18d2fa Mon Sep 17 00:00:00 2001 From: HampusM Date: Fri, 22 Jul 2022 13:25:45 +0200 Subject: refactor: make factories an optional feature --- README.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 34358cf..94eb526 100644 --- a/README.md +++ b/README.md @@ -13,11 +13,15 @@ From the [syrette Wikipedia article](https://en.wikipedia.org/wiki/Syrette). ## Features - A [dependency injection](https://en.wikipedia.org/wiki/Dependency_injection) container - Autowiring dependencies -- Binding factories - API inspired from the one of [InversifyJS](https://github.com/inversify/InversifyJS) - Helpful error messages - Enforces the use of interface traits +## Optional features +- Binding factories (Rust nightly required) + +To use these features, you must [enable it in Cargo](https://doc.rust-lang.org/cargo/reference/features.html#dependency-features). + ## Motivation Other DI libraries for Rust are either unmaintained ([di](https://crates.io/crates/di) for example), overcomplicated and or bloated ([anthill-di](https://crates.io/crates/anthill-di) for example) @@ -25,9 +29,6 @@ or has a weird API ([teloc](https://crates.io/crates/teloc) for example). The goal of Syrette is to be a simple, useful, convenient and familiar DI library. -## Notice -Rust nightly is currently required. - ## Example usage ```rust use syrette::{injectable, DIContainer}; -- cgit v1.2.3-18-g5258