You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ctx.register({
SomeService: {
type: ServiceType,
args: [args, for, some, service]
}
// If you wanted to get fancy
// You could even allow referencing other
// services by name.
AnotherService: {
type: AnotherType,
args: ['%SomeService%', other, args]
},
// Allow the ctx container to register singleton objects
// (not just class constructors
someConfig: {
foo: 'bar',
faz: 'baz
}
});
For larger applications, it would really clean things up to be able to separate our your ctx wiring from other application logic.
The text was updated successfully, but these errors were encountered:
Something like:
For larger applications, it would really clean things up to be able to separate our your ctx wiring from other application logic.
The text was updated successfully, but these errors were encountered: