Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Registry APIs: deprecate micro-syntax; introduce replacement API
Introduce a new, object-based API for all registry APIs; deprecate the current string-based microsyntax registry APIs; and introduce a `capabilities` property to the resolver to safely support existing resolvers. Extend the new API for service and controller injections, and deprecate their microsyntax for namespaced injections. Today the registry APIs are all of shapes roughly like this: getOwner(this).lookup('service:session'); This RFC proposes that they would instead be written like this: getOwner(this).lookup({ type: 'service', name: 'session' }) Service and controller injections which include a namespace currently look like this: class Example { @service('global@session') session; } This RFC proposes that these would instead be written like this: class Example { @service({ namespace: 'global', name: 'session' }) session; }
- Loading branch information