How to use the zip function from rxjs
Find comprehensive JavaScript rxjs.zip code examples handpicked from public code repositorys.
GitHub: openforis/sepal
121 122 123 124 125 126 127 128 129 130
} else { return throwError(() => e) } }), retryWhen(function (error$) { return zip( error$, range(1, retries + 1) ).pipe( mergeMap(
45
178
34
GitHub: caosbad/api
64 65 66 67 68 69 70 71 72 73
exports.race = rxjs.race; exports.range = rxjs.range; exports.throwError = rxjs.throwError; exports.timer = rxjs.timer; exports.using = rxjs.using; exports.zip = rxjs.zip; exports.scheduled = rxjs.scheduled; exports.EMPTY = rxjs.EMPTY; exports.NEVER = rxjs.NEVER; exports.config = rxjs.config;
299
0
1
84 85 86 87 88 89 90 91 92 93
mentorId: ctx.data.id, status: type, }) const countTotal = () => countMatchesByType(null) Rx.zip(getLastLoginDateTime(), countTotal()).subscribe( ([lastLoginDateTime, totalRedMatchCount]) => { Object.assign(ctx.data, { lastLoginDateTime, totalRedMatchCount,
7
18
6
+ 32 other calls in file
144 145 146 147 148 149 150 151 152 153
rxfilter((ad) => !isUndefined(ad.id)), concatMap((ad) => { let adset = Facebook.ad.adset.api.get({ adset_id: ad.adset_id, user_id, date, fb_ad_account_id }); let campaign = Facebook.ad.campaign.api.get({ campaign_id: ad.campaign_id, user_id, date, fb_ad_account_id }); return zip([adset, campaign]).pipe( rxmap(([{ name: adset_name }, { name: campaign_name }]) => ({ ...ad, adset_name, campaign_name })), rxmap(Facebook.ad.details) ); })
0
0
1
+ 5 other calls in file