I'm having a hard time understanding this:
const loadData: (detailsStore: RecipeDetailsStore) => (source$: Observable<string>) => Observable<RecipeDetails>
How should I interpret this?
My understanding is:
loadData
is a function that takes an argument of type RecipeDetailsStore
, and then it returns another function that accepts a parameter named source$
of type Observable<string>
. Ultimately, the return type is an Observable
of type RecipeDetails
? But I'm not entirely certain.
Or does it mean that loadData
is a function with a return type of
(detailsStore: RecipeDetailsStore) => (source$: Observable<string>) => Observable<RecipeDetails>
?
The double arrow is throwing me off. What does it signify?
I attempted to ask ChatGPT for help, but even ChatGPT seems confused and trapped in an infinite loop (a situation I've never encountered before with ChatGPT).