Created
May 29, 2018 10:40
-
-
Save langan/2a6191682ac6c93275ff2142e3afab58 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 { Component } from '@angular/core'; | |
import { Observable } from 'rxjs'; | |
import { WordpressService } from './wordpress.service'; | |
@Component({ | |
selector: 'app-root', | |
templateUrl: './app.component.html', | |
styleUrls: ['./app.component.scss'] | |
}) | |
export class AppComponent { | |
posts$: Observable<any[]>; | |
constructor(private wp: WordpressService) { | |
this.posts$ = this.wp.getPosts(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment