Skip to content

Transform hooks into slices of hooks #71

Closed
@samber

Description

@samber

We should be able to add multiple callbacks for each hook:

type InjectorOpts struct {
	HookAfterRegistration []func(scope *Scope, serviceName string)
	HookAfterShutdown     []func(scope *Scope, serviceName string)
        Logf                  []func(format string, args ...any)
}

instead of

type InjectorOpts struct {
	HookAfterRegistration func(scope *Scope, serviceName string)
	HookAfterShutdown     func(scope *Scope, serviceName string)
        Logf                  func(format string, args ...any)
}

Requirement for #70

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions