error TS2339: Property 'email' does not exist on type 'Object'

Replace (data) with (data : any) on 3rd line.


Property 'hostname' does not exist on type 'Object'.

I'm using Vue and typescript, error occurred on debug when trying to console.log this.dropdownItems[0].hostname after loading some data in. The error for me looks to be a typescript type check on the declaration of the variable:

dropdownItems: Array<Object> = []

should have been:

dropdownItems: any[] = []

Derived from: https://www.reddit.com/r/ionic/comments/9cxc79/property_courses_does_not_exist_on_type_object/

Tags:

Angular