你好,我有下面的代码:
public cards: Observable<Array<Card[]> = combineLatest(
INITIAL_DATA.map(card =>
this.resolveAsset(card.name).pipe(
map((uri: string): Card => ({
...card,
imageURI: uri,
})),
),
),
);
}
这会给我以下关于CombineLatest和Obserables的错误消息。
[ts]
Type 'OperatorFunction<{}, [{}, Observable<Card>]>' is not assignable to type 'Observable<Card[][]>'.
Property '_isScalar' is missing in type 'OperatorFunction<{}, [{}, Observable<Card>]>'.
(alias) class Observable<T>
import Observable
A representation of any set of values over any amount of time. This is the most basic building block of RxJS.
我的卡的界面模型如下:card.model.ts
export interface Card {
name: string;
balance: number;
imageURI: string;
}