I read JetNews sample I saw this statement ```val...
# compose
s
I read JetNews sample I saw this statement
Copy code
val (postsState, refreshPosts) = refreshableUiStateFrom(postsRepository::getPosts)
I am a kotlin beginner, mabye could someone explain what mean ?
t
k
The variables in the first part are "destructured" from the return value of the function call to refreshableUiStateFrom which takes an argument of type function (I'm not sure on the signature of the function from the sample), and the value being passed to it is the function getPosts contained inside the type postsRepository. Hope that helps.
s
@Tolriq @katokay - thanks you, I understood now.