Update trailingComma: es5 document (#15555)
This commit is contained in:
1 parent
e682577c08
commit
56945ecf12
2 files changed
+2
-2
No files matched your search
+1
-1
@@ -134,7 +134,7 @@ Print trailing commas wherever possible in multi-line comma-separated syntactic
|
|||||||
Valid options:
|
Valid options:
|
||||||
|
|
||||||
- `"all"` - Trailing commas wherever possible (including [function parameters and calls](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Trailing_commas#Trailing_commas_in_functions)). To run, JavaScript code formatted this way needs an engine that supports ES2017 (Node.js 8+ or a modern browser) or [downlevel compilation](https://babeljs.io/docs/en/index). This also enables trailing commas in type parameters in TypeScript (supported since TypeScript 2.7 released in January 2018).
|
- `"all"` - Trailing commas wherever possible (including [function parameters and calls](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Trailing_commas#Trailing_commas_in_functions)). To run, JavaScript code formatted this way needs an engine that supports ES2017 (Node.js 8+ or a modern browser) or [downlevel compilation](https://babeljs.io/docs/en/index). This also enables trailing commas in type parameters in TypeScript (supported since TypeScript 2.7 released in January 2018).
|
||||||
- `"es5"` - Trailing commas where valid in ES5 (objects, arrays, etc.). No trailing commas in type parameters in TypeScript.
|
- `"es5"` - Trailing commas where valid in ES5 (objects, arrays, etc.). Trailing commas in type parameters in TypeScript and Flow.
|
||||||
- `"none"` - No trailing commas.
|
- `"none"` - No trailing commas.
|
||||||
|
|
||||||
| Default | CLI Override | API Override |
|
| Default | CLI Override | API Override |
|
||||||
|
|||||||
@@ -122,7 +122,7 @@ Print trailing commas wherever possible in multi-line comma-separated syntactic
|
|||||||
Valid options:
|
Valid options:
|
||||||
|
|
||||||
- `"all"` - Trailing commas wherever possible (including [function parameters and calls](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Trailing_commas#Trailing_commas_in_functions)). To run, JavaScript code formatted this way needs an engine that supports ES2017 (Node.js 8+ or a modern browser) or [downlevel compilation](https://babeljs.io/docs/en/index). This also enables trailing commas in type parameters in TypeScript (supported since TypeScript 2.7 released in January 2018).
|
- `"all"` - Trailing commas wherever possible (including [function parameters and calls](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Trailing_commas#Trailing_commas_in_functions)). To run, JavaScript code formatted this way needs an engine that supports ES2017 (Node.js 8+ or a modern browser) or [downlevel compilation](https://babeljs.io/docs/en/index). This also enables trailing commas in type parameters in TypeScript (supported since TypeScript 2.7 released in January 2018).
|
||||||
- `"es5"` - Trailing commas where valid in ES5 (objects, arrays, etc.). No trailing commas in type parameters in TypeScript.
|
- `"es5"` - Trailing commas where valid in ES5 (objects, arrays, etc.). Trailing commas in type parameters in TypeScript and Flow.
|
||||||
- `"none"` - No trailing commas.
|
- `"none"` - No trailing commas.
|
||||||
|
|
||||||
| Default | CLI Override | API Override |
|
| Default | CLI Override | API Override |
|
||||||
|
|||||||
Reference in new issue
Block a user