Created
June 30, 2018 23:10
-
-
Save zkkmin/8b8ba4c55812fa3e3a51d4dc7dae9522 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Injectable } from '@angular/core'; | |
import { Observable } from 'rxjs'; | |
import { HttpClient } from '@angular/common/http'; | |
@Injectable({ | |
providedIn: 'root' | |
}) | |
export class QuoteService { | |
private quoteUrl = "https://talaikis.com/api/quotes/random/"; | |
getQuote(): Observable <{}> { | |
return this.http.get(this.quoteUrl) | |
}; | |
constructor( | |
private http: HttpClient | |
) { } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment