Proposing a conditional assignment (or equals) operator
Alexander Jones
alex at weej.com
Mon Aug 21 08:52:35 UTC 2017
For what it's worth, doubling down on a design that exposes such poor
choices wouldn't necessarily be a bad thing ;)
On Wed, 16 Aug 2017 at 02:56, kai zhu <kaizhu256 at gmail.com> wrote:
> this proposal is not as useful as you would think. when integrating
> with api's and modules not written by yourself, you will always be
> self-doubting whether the "other" guy who wrote their code used
> null/undefined/false/0/<empty string> values, causing you to avoid
> using this feature in general.
>
> the <empty string> is commonly treated as a defacto null when reading
> dom-element attributes or when fetching web-data
>
>
> On 8/15/17, Claude Pache <claude.pache at gmail.com> wrote:
> > This feature is more related to null coalescing (evaluate the RHS when
> the
> > LHS is null) than to optional chaining (evaluate the LHS when the LHS is
> > *not* null).
> >
> > See https://github.com/gisenberg/proposal-nullary-coalescing/issues/1
> > <https://github.com/gisenberg/proposal-nullary-coalescing/issues/1>
> >
> > —Claude
> >
> >> Le 15 août 2017 à 03:11, Ari Porad <ari at ariporad.com> a écrit :
> >>
> >> Hi All,
> >>
> >> Given that optional chaining is now stage–1, would there be interest in
> >> reviving this proposal? (This idea originated from my comment here
> >> <
> https://github.com/tc39/proposal-optional-chaining/issues/18#issuecomment-322329156
> >.)
> >>
> >> Apologies if this isn’t the proper way to suggest this idea, it’s my
> first
> >> time posting on es-discuss!
> >>
> >> _______________________________________________
> >> es-discuss mailing list
> >> es-discuss at mozilla.org <mailto:es-discuss at mozilla.org>
> >> https://mail.mozilla.org/listinfo/es-discuss
> >> <https://mail.mozilla.org/listinfo/es-discuss>
> >
> >
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20170821/80050c77/attachment.html>
More information about the es-discuss
mailing list