Guest User

Untitled

a guest
Jul 18th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. {"test": "test", "test2": 15}
  2.  
  3. public getTests(): Observable<Test[]> {
  4. return this.http.get<Test[]>(environment.api + '/tests'); }
  5.  
  6. loadTests() {
  7. this.testsService.getTests().subscribe(response => {
  8. console.log(response);
  9. this.tests = response;
  10. });
  11.  
  12. {"changed": "test", "changed2": 15}
  13.  
  14. this.testsService.getTests().subscribe(mapToSomething)
Add Comment
Please, Sign In to add comment