Ilya P
04/18/2024, 9:14 AMLoaderFunction
now. Lambdas are no longer compatible with the type. E.g. this used to work: loader = { scope.promise { fetchX() } }
but now it doesn't compile because Type mismatch: inferred type is () -> Promise<List<WebNativeServerInfo>> but LoaderFunction<Any?>? was expected
Ilya P
04/18/2024, 9:22 AMIlya P
04/18/2024, 9:27 AMIlya P
04/18/2024, 9:37 AMprivate val PageLoader: LoaderFunction<Any?> = {
resolve(MATERIAL_SHOWCASES)
}.unsafeCast<LoaderFunction<Any?>>()
Ilya P
04/18/2024, 9:38 AMgbaldeck
04/18/2024, 11:25 AMIlya P
04/18/2024, 12:33 PMIlya P
04/18/2024, 12:33 PMgbaldeck
04/18/2024, 1:05 PMturansky
04/19/2024, 11:28 AMasDynamic
, unsafeCast
- please report issue.turansky
04/19/2024, 1:58 PMpre.732
released 🎉Hildebrandt Tobias
06/04/2024, 8:30 AMLoaderFunction
adapter is not there anymore and I get the error Interface LoaderFunction does not have constructors
turansky
06/04/2024, 8:33 AMLoaderFunction
factory is here.
It's signature was changed by authors.
Probably you missed second parameterHildebrandt Tobias
06/04/2024, 8:42 AMval deviceLoader = LoaderFunction<Any?> { args, context ->
PromiseResult(Unit)
}
Following the LoaderFunction
reference leads me to:
typealias LoaderFunction<Context> = (args: LoaderFunctionArgs<Context>) -> Any? /* Promise<DataFunctionValue> | DataFunctionValue */
turansky
06/04/2024, 8:44 AMHildebrandt Tobias
06/04/2024, 8:44 AMHildebrandt Tobias
06/04/2024, 8:45 AMturansky
06/04/2024, 8:45 AMHildebrandt Tobias
06/04/2024, 8:46 AMturansky
06/04/2024, 8:46 AMHildebrandt Tobias
06/04/2024, 8:47 AM