Function: ServiceMiddleware()
Function: ServiceMiddleware()
function ServiceMiddleware(context, next): Promise<IBlueprint>;
Middleware to add services to the blueprint.
This middleware identifies modules marked as services and adds them to the blueprint's list of services.
Parameters
context
BlueprintContext
<IBlueprint
, ClassType
>
The configuration context containing modules and blueprint.
next
NextPipe
<BlueprintContext
<IBlueprint
, ClassType
>, IBlueprint
>
The next function in the pipeline.
Returns
Promise
<IBlueprint
>
The updated blueprint.
Example
ServiceMiddleware({ modules, blueprint }, next);