I am trying to get all the data from mongodb but it shows [object] [object] how do I get array data to angular from mongodb?
Here is my code:
import { Component, OnInit } from '@angular/core';
import {HttpClient} from "@angular/common/http";
import {Model} from "../model/model";
@Component({
selector: 'app-take-quiz',
templateUrl: './take-quiz.component.html',
styleUrls: ['./take-quiz.component.css']
})
export class TakeQuizComponent implements OnInit {
data:Model[]=[];
constructor(private http:HttpClient) { }
ngOnInit(){
this.quizAll();
}
quizAll(){
this.http.get<any>('https://localhost:8080/quizzes/').subscribe(response=>
{
console.log(response);
// @ts-ignore
this.data=response;
});
}
}
model.ts
export interface Model {
title:string;
description:string;
}
html
<div>
<p>your data {{data}}</p>
</div>
Here is the screenshot of console 
when I try
<div>
<p>your data {{data.title}}</p>
</div>
