factory creates view model