-
-
Notifications
You must be signed in to change notification settings - Fork 291
Closed
Description
Several times at https://docs.nativescript.org/angular/ng-framework-modules/http, it is made clear that
Note that the services should be explicitly declared in providers
There are other ways to do DI in angular, notably
@Injectable({
providedIn: 'root',
})
export class MyAwesomeDataService{
// Service code...
}or specifying an NgModule in the provided in option.
Are these also ok?
If they are ok, the documentation should be less "opinionated" in tone, and if it's not ok (or just not reccomended) the docs should say why.