make layouts work in ViewModel.