babel-preset-es2015-node6 icon indicating copy to clipboard operation
babel-preset-es2015-node6 copied to clipboard

Node 6 support destructuring and function name

Open Pana opened this issue 8 years ago • 7 comments

FYI

Pana avatar Apr 28 '16 02:04 Pana

Thanks!

The destructuring is related to #2, I believe it will be removed in the near future.

Currently the function-name has many of the features we need to enable --harmony-function-name in v8 5.0, so I still keep it.

jhen0409 avatar Apr 28 '16 02:04 jhen0409

I'm not sure I understand why function-name is included. It seems to be supported natively in Node v6.

olalonde avatar Sep 12 '16 03:09 olalonde

@olalonde you can see function "name" property in ES6 compatibility table, currently babel has two features we need enable --harmony-function-name on node 6:

  • variables (function)
  • object methods (function)

jhen0409 avatar Sep 12 '16 04:09 jhen0409

Ah ok, thanks.

olalonde avatar Sep 12 '16 07:09 olalonde

Yes, but as you can see in node.green the function name features are supported in node 6.5 because v8 was updated to 5.1

christophehurpeau avatar Sep 15 '16 10:09 christophehurpeau

Maybe we could use the preset es2015-node6/node6.5 ?

christophehurpeau avatar Sep 15 '16 10:09 christophehurpeau

@christophehurpeau, sorry for delay..

I think with the latest version will be better, so may I'll provide like less-than-6.5 preset.

jhen0409 avatar Nov 02 '16 11:11 jhen0409