Display events to angular angular full calendar


    	{ title: 'event 1', date: '2019-06-07' },
    { title: 'event 2', date: '2019-06-12' }

and this how look


everything is fine but ı want load event from json instead of “[events]” array and ı made service


export class ScheduleProvider {

  constructor(public http: HttpClient) {
    console.log('Hello ScheduleProvider Provider');

    return this.http.get<any[]>('url/events');


this my json url/events

{“data”:[{“id”:1,“name”:"subject 1"“start_time”:“2019-07-21 00:00:00”},{“id”:2,“name”:"subject 2"“start_time”:“2019-07-28 00:00:00”},{“id”:3,“name”:"subject 3"“start_time”:“2019-07-30 00:00:00”}]}





ı dont know how to display jsonEvents in calendar instead of events array . So please help me.

Change the binding from the string to the variable that you are setting from within the API call. Obviously, the data returned will have to match the format expected by the control. If not, you’ll have to massaging of the data.

sorry but ı didnt get you really can you give more explain

Replace the json that you have bound events to with the jsonEvents variable. In looking at the data returned from you API call, it appears that the fields are different than what appears within the inline JSON that events is bound to. I don’t know anything about this particular control.

If it were me, I would create a class whose fields match the fields of the control. I would then iterate over the data returned and create new objects for each entry. Those entries would be added to an array and that array would be assigned to jsonEvents.