Pattern matching?

kai zhu kaizhu256 at
Fri Jun 30 15:45:19 UTC 2017

-1.  will pattern matching code written by the vast number of beginner
javascript programmers be readable/maintainable? i personally think not.
yet another duplicative feature (that can probably be done more
maintainably by switch statements or the all-powerful
String.prototype.replace) to further muddle the confusing state of "best
coding-practices" for javascript.


On Jun 30, 2017 10:46 PM, "Sebastian Malton" <sebastian at> wrote:
> Are you thinking kind of like Rust's match statement? I think that
something like that would be quite a good addition.
> Sebastian
> From: henrik.sommerland at
> Sent: June 30, 2017 9:55 AM
> To: es-discuss at
> Subject: Pattern matching?
> Why is there no support for pattern matching in JavaScript?
> I would guess that it has been proposed before, and if so why hasn't it
been included?
> I have been thinking about it and I think it would integrate nicely into
> If it hasn't been proposed already I would propose it, and I would gladly
look into it more and try to examine what kind of semantics would be
> Peace!
> --
> Henrik "TheGrandmother" Sommerland
> _______________________________________________
> es-discuss mailing list
> es-discuss at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list