I would like to pass an array of objects from my js file to an aura attribute. I know the list contains values and is correct before I pass it to the aura component but the list is empty when I log that attribute to the console.

Helper method:

    //convert map into list of objects for Aura
                    var objects = [];
                    for(var rawLineItem in result.rawLineItemToContactIdList) {
                        objects.push({key:rawLineItem, value:result.rawLineItemToContactIdList[rawLineItem]});
                        console.log('objects: ' + JSON.stringify(objects));
                    }
                    component.set("v.objectList", objects);


Aura attribute:

    <aura:attribute name="objectList" type="List" />