Rxjs: [docs]: Rename/Alias the exhaust operator to exhaustAll

Created on 16 Feb 2019  路  7Comments  路  Source: ReactiveX/rxjs

Bug Report

Current Behavior
All good! Just the naming might be confusing.

Possible Solution
I would expect the name of exhaust to be exhaustAll.

Additional context/Screenshots
If you take a look into the code you will realize that all the other operators like switchAll, mergeAll, zipAll etc. process higher order observables like exhaust do.

Therefore I consider the naming as inconsistent.

I would suggest to implement it as an alias.

Help Wanted

Most helpful comment

(and I think we should deprecate exhaust while we're add it)... it would be nice to have the names be uniform.

All 7 comments

IIRC, switchAll was called switch when it was a prototype-patching operator.

The prototype-patching concatAll and mergeAll operators had All appended to differentiate them from concat and merge - not specifically because the All implied a higher-order observable.

When switch was made into a pipeable operator had to be renamed - for the obvious reason - and it was renamed to switchAll.

But I agree that exhaustAll would be more consistent.

Thanks for the nice history!

not specifically because the All implied a higher-order observable

Maybe you know what the meaning for All was back then, if not a hint to higher order observables?

I think we should do this, honestly.

(and I think we should deprecate exhaust while we're add it)... it would be nice to have the names be uniform.

it would be nice to have the names be uniform

NIT:
Consider rethinking combineAll too. To have it really uniform it should be named combineLatestAll :)

rx-all

Team agreement: Rename it to exhaustAll.

Will do!

Was this page helpful?
0 / 5 - 0 ratings