-
Notifications
You must be signed in to change notification settings - Fork 29.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiline function arguments with trailing comma - SyntaxError: Unexpected token ) #11258
Comments
@davegri If I get it right, the airbnb rule imply Bebel transpiling for now. Even the last v8 version (5.7) does not support trailing commas in function parameter lists and calls yet. However, you can use |
Closing as not a bug. Node core would support trailing comma by default when V8 turns it on by default, right now the |
It seems V8 5.8 will support them without a flag: these trailing commas are OK in the current Chrom Canary with V8 5.8. |
In which version of node is supported? |
From Node.js 8 (at least in the last 08.11.1 it is supported). |
v7.5.0
Darwin Johns-MacBook-Pro.local 16.1.0 Darwin Kernel Version 16.1.0: Wed Oct 19 20:31:56 PDT 2016; root:xnu-3789.21.4~4/RELEASE_X86_64 x86_64
The following code:
throws a syntax error:
I would like to be able to comply with the airbnb style guide which requires a trailing comma
The text was updated successfully, but these errors were encountered: