Viewmodel and Functions
Hi hivemind,
I’m trying to use a slider as input for a simplified function using a Viewmodel (to get the hang of proper MVVM architecture) but I’m getting ‘type mismatch’ and ‘no value passed’ errors - any ideas?
The function takes the float output of the slider (sliderP1) inverts it, and displays the output on the screen (cog).
MainScreen(
sliderP1 = viewModel.sliderP1,
onValueChange = {viewModel.sliderP1 = it},
onValueChangeFinished = {},
cog = viewModel.cog,
calcs =...