completion refactoring, support for arrays, nested objects etc