from array to object of imports