constructor-injection
CommunityEfficiently initialize complex types with constructor injection in Rust.
Software Engineering#rust#dependency injection#constructor injection#async initialization#custom construction
Authorjymchng
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill solves the challenge of initializing complex types in Rust, especially those with non-injectable fields, async initialization, or custom construction logic.
Core Features & Use Cases
- Constructor Injection: Provides a way to initialize types with constructor injection, making it easier to manage complex initialization logic.
- Async Initialization: Supports async initialization for types that require asynchronous operations.
- Custom Construction Logic: Allows for custom construction logic when the default constructor does not suffice.
- Use Case: When you have a database configuration that needs to read environment variables at startup and establish a connection to the database.
Quick Start
Initialize a new instance of AppConfig using constructor injection.
Dependency Matrix
Required Modules
injectabletokio
Components
scriptsreferences
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: constructor-injection Download link: https://github.com/jymchng/injectable/archive/main.zip#constructor-injection Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 620,000+ vetted skills library on demand.