@Injectable({
providedIn: 'root', //to create a single service, at root level
})
export class AppService{}
@NgModule({
providers: [AppService],
...
})
@Component({
selector: 'app-demo',
templateUrl: './demo.component.html',
providers: [ AppService ]
})
export class AppComponent {
private data:any[] = [];
constructor(
private appService: AppService
) { }
getData() {
this.appService.getList().subscribe( resp => {
this.data = resp;
});
}
}
import { Injectable } from '@angular/core';
@Injectable({
providedIn: 'root',
})
export class DemoService {
}
If you want to sell your readymade software to the genuine clients or businessman, list your software with details and demo links.
Clients will find it using our advanced search filter and will contact you directly.
No any charge for the product lsiting.