Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- interface Note{
- imageUrl: string;
- title: string;
- body: string;
- titledesc: string;
- imgalt: string;
- imgdesc: string;
- imgtitle: string;
- authorId: string;
- }
- notesCollection: AngularFirestoreCollection<Note>;
- notes: Observable<Note[]>;
- getAuthorData = function(blog: string){
- this.notesCollection = this.afs.collection('/Blogs', ref =>{
- return ref.where('title','==', blog)
- }).valueChanges()
- this.notesCollection.subscribe( data => {
- console.log(data.authorId)
- });
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement