import { Injectable } from '@angular/core'; | |
import { HttpClient } from '@angular/common/http'; | |
import { Movie } from '../models/index'; | |
@Injectable() | |
export class CinemaService { | |
constructor(protected http: HttpClient) {} | |
getMovies() { | |
return this.http.get<Movie[]>(`/api/movies`); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment