-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
bugSomething isn't workingSomething isn't working
Description
When the providers key of NgModule ends with a provider object (like {provide: '', useValue: ''}) the method addProviderToModule has an unexpected result :
@NgModule({
providers: [
{ provide: '', useValue: '', providers: [{ provide: TOKEN, useValue: 'someValue' }] }
]
})I've run some tests :
- works :
providers: [SomeProvider] - works :
providers: [{ provide: '', useValue: '' } as Provider] - works :
providers: [{ provide: '', useValue: '' }, SomeProvider] - fails:
providers: [{ provide: '', useValue: '' }] - fails:
providers: [SomeProvider, { provide: '', useValue: '' }]
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working