parent
67ad59c245
commit
7d006c5005
|
@ -38,18 +38,14 @@ import {defineInjectable} from './defs';
|
|||
*
|
||||
* @usageNotes
|
||||
* ### Basic Example
|
||||
|
||||
* #### Tree-shakable InjectionToken
|
||||
*
|
||||
* {@example core/di/ts/injector_spec.ts region='ShakeableInjectionToken'}
|
||||
*
|
||||
* #### Plain InjectionToken
|
||||
*
|
||||
* {@example core/di/ts/injector_spec.ts region='InjectionToken'}
|
||||
*
|
||||
* ### Tree-shakeable Example
|
||||
* #### Tree-shakable InjectionToken
|
||||
*
|
||||
* {@example core/di/ts/injector_spec.ts region='ShakeableInjectionToken'}
|
||||
* {@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}
|
||||
*
|
||||
*/
|
||||
export class InjectionToken<T> {
|
||||
|
|
|
@ -61,7 +61,7 @@ class MockRootScopeInjector implements Injector {
|
|||
const injector =
|
||||
new MockRootScopeInjector(Injector.create({providers: [{provide: MyDep, deps: []}]}));
|
||||
|
||||
// #docregion ShakeableInjectionToken
|
||||
// #docregion ShakableInjectionToken
|
||||
class MyService {
|
||||
constructor(readonly myDep: MyDep) {}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue