Docs (4.0.0)
class GlobalContext method

addService

Adds a service to the global application context.

addService(service: Service): this

Summary

This method adds a global service to the current ServiceContext, i.e. app.services. This allows other parts of the application to find and observe the service.

Parameters

  • service — The service to be added, must have a valid id property

Related