Shorthand and function enhancement for named arguments (draft proposal included)

Hello here is my proposal. Discuss it.

Also what actual text need to be added for it to be implemented besides the syntax change.

Added a more complex case where an actual object with identifier matching a function parameter is passed as argument.

And what's the usecase? I mean, why would you need named arguments? And what are there exact semantics? Does it match the arguments name to the parameter? If so how?

Also given that : is already used for labels, object destructuring and object literals I'm not convinced that yet another usage of it is needed.

1 Like